mirror of
https://github.com/status-im/nim-dagger.git
synced 2025-01-09 14:15:41 +00:00
code cleanup
This commit is contained in:
parent
beae8a4283
commit
2bae744c5c
@ -40,10 +40,9 @@ proc buildBinary(name: string, srcDir = "./", params = "", lang = "c") =
|
|||||||
try:
|
try:
|
||||||
exec(cmd)
|
exec(cmd)
|
||||||
finally:
|
finally:
|
||||||
if defined(macosx):
|
if defined(macosx):
|
||||||
renameFile(newVersionFile, oldVersionFile)
|
renameFile(newVersionFile, oldVersionFile)
|
||||||
|
|
||||||
|
|
||||||
proc test(name: string, srcDir = "tests/", params = "", lang = "c") =
|
proc test(name: string, srcDir = "tests/", params = "", lang = "c") =
|
||||||
buildBinary name, srcDir, params
|
buildBinary name, srcDir, params
|
||||||
exec "build/" & name
|
exec "build/" & name
|
||||||
|
@ -90,4 +90,4 @@ proc getAddressAndPort*(ma: MultiAddress): tuple[ip: Option[ValidIpAddress], por
|
|||||||
|
|
||||||
result = (ip: ip, port: port)
|
result = (ip: ip, port: port)
|
||||||
except Exception:
|
except Exception:
|
||||||
result = (ip: none(ValidIpAddress), port: none(Port))
|
result = (ip: none(ValidIpAddress), port: none(Port))
|
||||||
|
@ -43,4 +43,4 @@ suite "NAT Address Tests":
|
|||||||
|
|
||||||
# Verify results
|
# Verify results
|
||||||
check(discoveryAddrs == expectedDiscoveryAddrs)
|
check(discoveryAddrs == expectedDiscoveryAddrs)
|
||||||
check(libp2pAddrs == expectedlibp2pAddrs)
|
check(libp2pAddrs == expectedlibp2pAddrs)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user