Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-dms3-pq
Commits
cbc2990c
Commit
cbc2990c
authored
Oct 30, 2019
by
Dirk McCormick
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
test: add Peek() ordering test
parent
528751cd
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
pq_test.go
pq_test.go
+4
-1
No files found.
pq_test.go
View file @
cbc2990c
...
@@ -58,9 +58,12 @@ func TestCorrectnessOfPop(t *testing.T) {
...
@@ -58,9 +58,12 @@ func TestCorrectnessOfPop(t *testing.T) {
priorities
=
append
(
priorities
,
i
)
priorities
=
append
(
priorities
,
i
)
peekPriorities
=
append
(
peekPriorities
,
i
)
peekPriorities
=
append
(
peekPriorities
,
i
)
}
}
if
!
sort
.
IntsAreSorted
(
priorities
)
{
if
!
sort
.
IntsAreSorted
(
p
eekP
riorities
)
{
t
.
Fatal
(
"the values were not returned in sorted order"
)
t
.
Fatal
(
"the values were not returned in sorted order"
)
}
}
if
!
sort
.
IntsAreSorted
(
priorities
)
{
t
.
Fatal
(
"the popped values were not returned in sorted order"
)
}
}
}
func
TestUpdate
(
t
*
testing
.
T
)
{
func
TestUpdate
(
t
*
testing
.
T
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment