mirror of
https://github.com/logos-storage/logos-storage-nim-dht.git
synced 2026-01-04 06:23:05 +00:00
setup to use env variable for parallel tests
This commit is contained in:
parent
cdd03ea3e9
commit
71269839f7
13
build.nims
13
build.nims
@ -1,10 +1,14 @@
|
|||||||
import std / [os, strutils, sequtils]
|
import std / [os, strutils]
|
||||||
|
|
||||||
when declared(getPathsClause):
|
when declared(getPathsClause):
|
||||||
proc nimc(): string = "nim c " & getPathsClause()
|
proc nimc(): string =
|
||||||
|
# set this for compiling parallel tests
|
||||||
|
putEnv("NIMBLE_PATHS", getPathsClause().split(" ").join($PathSep & $PathSep))
|
||||||
|
"nim c " & getPathsClause()
|
||||||
else:
|
else:
|
||||||
proc nimc(): string = "nim c"
|
proc nimc(): string =
|
||||||
proc getPathsClause(): string = ""
|
putEnv("NIMBLE_PATHS", "")
|
||||||
|
"nim c "
|
||||||
|
|
||||||
switch("define", "libp2p_pki_schemes=secp256k1")
|
switch("define", "libp2p_pki_schemes=secp256k1")
|
||||||
|
|
||||||
@ -12,7 +16,6 @@ task testAll, "Run DHT tests":
|
|||||||
exec nimc() & " -r tests/testAll.nim"
|
exec nimc() & " -r tests/testAll.nim"
|
||||||
|
|
||||||
task test, "Run DHT tests":
|
task test, "Run DHT tests":
|
||||||
putEnv("NIMBLE_PATHS", getPathsClause().split(" ").join($PathSep & $PathSep))
|
|
||||||
exec nimc() & " -r -d:testsAll --verbosity:0 tests/testAllParallel.nim"
|
exec nimc() & " -r -d:testsAll --verbosity:0 tests/testAllParallel.nim"
|
||||||
|
|
||||||
task testPart1, "Run DHT tests A":
|
task testPart1, "Run DHT tests A":
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user