2019-02-05 12:10:36 +02:00
|
|
|
version = "1.0.0"
|
|
|
|
author = "Status Research & Development GmbH"
|
|
|
|
description = "Ethereum Common library"
|
|
|
|
license = "MIT"
|
|
|
|
skipDirs = @["tests"]
|
|
|
|
|
2020-04-18 07:21:13 +02:00
|
|
|
requires "nim >= 1.2.0",
|
2019-02-05 12:10:36 +02:00
|
|
|
"nimcrypto",
|
|
|
|
"stint",
|
2019-02-05 16:06:13 +02:00
|
|
|
"secp256k1",
|
2019-02-05 17:54:17 +02:00
|
|
|
"rocksdb",
|
2019-02-06 19:11:29 +01:00
|
|
|
"chronos",
|
2019-03-11 11:22:06 +02:00
|
|
|
"chronicles",
|
2019-07-07 11:55:17 +02:00
|
|
|
"stew",
|
2019-07-10 02:08:35 +02:00
|
|
|
"nat_traversal",
|
2019-09-05 22:55:30 -04:00
|
|
|
"metrics"
|
2019-02-05 12:32:22 +02:00
|
|
|
|
2019-03-25 22:22:02 +01:00
|
|
|
proc runTest(path: string) =
|
|
|
|
echo "\nRunning: ", path
|
2020-04-18 10:17:59 +02:00
|
|
|
exec "nim c -r -d:release -d:chronicles_log_level=ERROR --verbosity:0 --hints:off " & path
|
2019-03-25 22:22:02 +01:00
|
|
|
rmFile path
|
2019-02-05 12:10:36 +02:00
|
|
|
|
2019-03-25 22:22:02 +01:00
|
|
|
proc runKeyfileTests() =
|
|
|
|
for filename in [
|
|
|
|
"test_keyfile",
|
|
|
|
"test_uuid",
|
|
|
|
]:
|
|
|
|
runTest("tests/keyfile/" & filename)
|
2019-02-15 15:46:44 +01:00
|
|
|
|
|
|
|
task test_keyfile, "run keyfile tests":
|
2019-03-25 22:22:02 +01:00
|
|
|
runKeyfileTests()
|
|
|
|
|
|
|
|
proc runKeysTests() =
|
|
|
|
for filename in [
|
|
|
|
"test_keys",
|
2020-02-19 11:21:23 +02:00
|
|
|
"test_private_public_key_consistency"
|
2019-03-25 22:22:02 +01:00
|
|
|
]:
|
|
|
|
runTest("tests/keys/" & filename)
|
2019-02-15 15:46:44 +01:00
|
|
|
|
|
|
|
task test_keys, "run keys tests":
|
2019-03-25 22:22:02 +01:00
|
|
|
runKeysTests()
|
|
|
|
|
|
|
|
proc runP2pTests() =
|
|
|
|
for filename in [
|
|
|
|
"les/test_flow_control",
|
|
|
|
"test_auth",
|
|
|
|
"test_crypt",
|
|
|
|
"test_discovery",
|
|
|
|
"test_ecies",
|
|
|
|
"test_enode",
|
2019-10-22 15:14:14 +02:00
|
|
|
"test_rlpx_thunk",
|
2019-03-25 22:22:02 +01:00
|
|
|
"test_shh",
|
2019-11-19 14:08:20 +01:00
|
|
|
"test_shh_config",
|
2019-03-25 22:22:02 +01:00
|
|
|
"test_shh_connect",
|
2019-12-20 11:56:12 +01:00
|
|
|
"test_waku_connect",
|
2019-11-19 17:22:35 +01:00
|
|
|
"test_waku_bridge",
|
2019-12-06 00:45:14 +01:00
|
|
|
"test_waku_mail",
|
2019-04-11 15:08:32 +02:00
|
|
|
"test_protocol_handlers",
|
2019-12-10 20:34:57 +02:00
|
|
|
"test_enr",
|
2020-02-17 18:04:29 +01:00
|
|
|
"test_discoveryv5",
|
|
|
|
"test_discv5_encoding"
|
2019-03-25 22:22:02 +01:00
|
|
|
]:
|
|
|
|
runTest("tests/p2p/" & filename)
|
2019-02-15 15:46:44 +01:00
|
|
|
|
|
|
|
task test_p2p, "run p2p tests":
|
2019-03-25 22:22:02 +01:00
|
|
|
runP2pTests()
|
|
|
|
|
|
|
|
proc runRlpTests() =
|
2020-04-18 10:17:59 +02:00
|
|
|
runTest("tests/rlp/all_tests")
|
2019-02-15 15:46:44 +01:00
|
|
|
|
|
|
|
task test_rlp, "run rlp tests":
|
2019-03-25 22:22:02 +01:00
|
|
|
runRlpTests()
|
|
|
|
|
|
|
|
proc runTrieTests() =
|
2020-04-18 10:17:59 +02:00
|
|
|
runTest("tests/trie/all_tests")
|
2019-02-15 15:46:44 +01:00
|
|
|
|
|
|
|
task test_trie, "run trie tests":
|
2019-03-25 22:22:02 +01:00
|
|
|
runTrieTests()
|
|
|
|
|
|
|
|
task test, "run tests":
|
|
|
|
for filename in [
|
|
|
|
"test_bloom",
|
|
|
|
"test_common",
|
|
|
|
]:
|
|
|
|
runTest("tests/" & filename)
|
|
|
|
|
|
|
|
runKeyfileTests()
|
|
|
|
runKeysTests()
|
|
|
|
runP2pTests()
|
|
|
|
runRlpTests()
|
|
|
|
runTrieTests()
|
2019-02-15 15:46:44 +01:00
|
|
|
|