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
p2p
go-cidranger
Commits
6947c077
Commit
6947c077
authored
Dec 22, 2019
by
Yulin Chen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Mark comparison tests against brute ranger skippable in mode
parent
81d43541
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
0 deletions
+9
-0
cidranger_test.go
cidranger_test.go
+9
-0
No files found.
cidranger_test.go
View file @
6947c077
...
...
@@ -46,6 +46,9 @@ func TestCoveredNetworksAgainstBaseIPv6(t *testing.T) {
}
func
testContainsAgainstBase
(
t
*
testing
.
T
,
iterations
int
,
ipGen
ipGenerator
)
{
if
testing
.
Short
()
{
t
.
Skip
(
"Skipping memory test in `-short` mode"
)
}
rangers
:=
[]
Ranger
{
NewPCTrieRanger
()}
baseRanger
:=
newBruteRanger
()
for
_
,
ranger
:=
range
rangers
{
...
...
@@ -66,6 +69,9 @@ func testContainsAgainstBase(t *testing.T, iterations int, ipGen ipGenerator) {
}
func
testContainingNetworksAgainstBase
(
t
*
testing
.
T
,
iterations
int
,
ipGen
ipGenerator
)
{
if
testing
.
Short
()
{
t
.
Skip
(
"Skipping memory test in `-short` mode"
)
}
rangers
:=
[]
Ranger
{
NewPCTrieRanger
()}
baseRanger
:=
newBruteRanger
()
for
_
,
ranger
:=
range
rangers
{
...
...
@@ -89,6 +95,9 @@ func testContainingNetworksAgainstBase(t *testing.T, iterations int, ipGen ipGen
}
func
testCoversNetworksAgainstBase
(
t
*
testing
.
T
,
iterations
int
,
netGen
networkGenerator
)
{
if
testing
.
Short
()
{
t
.
Skip
(
"Skipping memory test in `-short` mode"
)
}
rangers
:=
[]
Ranger
{
NewPCTrieRanger
()}
baseRanger
:=
newBruteRanger
()
for
_
,
ranger
:=
range
rangers
{
...
...
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