chore: refactor relative path to better absolute (#2861)

This commit is contained in:
Darshan K 2024-07-06 03:33:38 +05:30 committed by GitHub
parent 3a93d13067
commit 8da2a9c0a5
146 changed files with 617 additions and 568 deletions

View File

@ -3,11 +3,13 @@ import
std/sequtils, std/sequtils,
stew/results, stew/results,
options, options,
../../waku/waku_rln_relay/protocol_types, waku/[
../../waku/waku_rln_relay/rln, waku_rln_relay/protocol_types,
../../waku/waku_rln_relay, waku_rln_relay/rln,
../../waku/waku_rln_relay/conversion_utils, waku_rln_relay,
../../waku/waku_rln_relay/group_manager/static/group_manager waku_rln_relay/conversion_utils,
waku_rln_relay/group_manager/static/group_manager,
]
import std/[times, os] import std/[times, os]

View File

@ -31,18 +31,20 @@ import
nameresolving/dnsresolver, nameresolving/dnsresolver,
] # define DNS resolution ] # define DNS resolution
import import
../../waku/waku_core, waku/[
../../waku/waku_lightpush/common, waku_core,
../../waku/waku_lightpush/rpc, waku_lightpush/common,
../../waku/waku_enr, waku_lightpush/rpc,
../../waku/discovery/waku_dnsdisc, waku_enr,
../../waku/waku_store_legacy, discovery/waku_dnsdisc,
../../waku/waku_node, waku_store_legacy,
../../waku/node/waku_metrics, waku_node,
../../waku/node/peer_manager, node/waku_metrics,
../../waku/factory/builder, node/peer_manager,
../../waku/common/utils/nat, factory/builder,
../../waku/waku_relay, common/utils/nat,
waku_relay,
],
./config_chat2 ./config_chat2
import libp2p/protocols/pubsub/rpc/messages, libp2p/protocols/pubsub/pubsub import libp2p/protocols/pubsub/rpc/messages, libp2p/protocols/pubsub/pubsub

View File

@ -10,7 +10,7 @@ import
nimcrypto/utils, nimcrypto/utils,
std/strutils, std/strutils,
regex regex
import ../../../waku/waku_core import waku/waku_core
type type
Fleet* = enum Fleet* = enum

View File

@ -1,3 +1,4 @@
-d:chronicles_line_numbers -d:chronicles_line_numbers
-d:chronicles_runtime_filtering:on -d:chronicles_runtime_filtering:on
-d:discv5_protocol_id:d5waku -d:discv5_protocol_id:d5waku
path = "../.."

View File

@ -13,16 +13,18 @@ import
eth/net/nat, eth/net/nat,
json_rpc/rpcserver, json_rpc/rpcserver,
# Matterbridge client imports # Matterbridge client imports
../../waku/common/utils/matterbridge_client,
# Waku v2 imports # Waku v2 imports
libp2p/crypto/crypto, libp2p/crypto/crypto,
libp2p/errors, libp2p/errors,
../../../waku/waku_core, waku/[
../../../waku/waku_node, waku_core,
../../../waku/node/peer_manager, waku_node,
../../waku/waku_filter_v2, node/peer_manager,
../../waku/waku_store, waku_filter_v2,
../../waku/factory/builder, waku_store,
factory/builder,
common/utils/matterbridge_client,
],
# Chat 2 imports # Chat 2 imports
../chat2/chat2, ../chat2/chat2,
# Common cli config # Common cli config
@ -178,6 +180,7 @@ proc new*(
let nodev2 = block: let nodev2 = block:
var builder = WakuNodeBuilder.init() var builder = WakuNodeBuilder.init()
builder.withNodeKey(nodev2Key) builder.withNodeKey(nodev2Key)
builder builder
.withNetworkConfigurationDetails( .withNetworkConfigurationDetails(
nodev2BindIp, nodev2BindPort, nodev2ExtIp, nodev2ExtPort nodev2BindIp, nodev2BindPort, nodev2ExtIp, nodev2ExtPort
@ -239,7 +242,7 @@ proc stop*(cmb: Chat2MatterBridge) {.async: (raises: [Exception]).} =
{.pop.} {.pop.}
# @TODO confutils.nim(775, 17) Error: can raise an unlisted exception: ref IOError # @TODO confutils.nim(775, 17) Error: can raise an unlisted exception: ref IOError
when isMainModule: when isMainModule:
import ../../../waku/common/utils/nat, ../../waku/waku_api/message_cache import waku/common/utils/nat, waku/waku_api/message_cache
let let
rng = newRng() rng = newRng()

View File

@ -1,3 +1,4 @@
-d:chronicles_line_numbers -d:chronicles_line_numbers
-d:chronicles_runtime_filtering:on -d:chronicles_runtime_filtering:on
-d:discv5_protocol_id:d5waku -d:discv5_protocol_id:d5waku
path = "../.."

View File

@ -13,11 +13,7 @@ import
json_serialization as js, json_serialization as js,
times times
import import
../../../waku/common/logging, waku/[common/logging, node/peer_manager, waku_node, waku_core, waku_filter_v2/client],
../../../waku/node/peer_manager,
../../../waku/waku_node,
../../../waku/waku_core,
../../../waku/waku_filter_v2/client,
./tester_config, ./tester_config,
./tester_message, ./tester_message,
./statistics ./statistics

View File

@ -7,11 +7,7 @@ import
stew/results, stew/results,
json_serialization as js json_serialization as js
import import
../../../waku/common/logging, waku/[common/logging, waku_node, node/peer_manager, waku_core, waku_lightpush/client],
../../../waku/waku_node,
../../../waku/node/peer_manager,
../../../waku/waku_core,
../../../waku/waku_lightpush/client,
./tester_config, ./tester_config,
./tester_message ./tester_message

View File

@ -11,12 +11,14 @@ import
confutils confutils
import import
../../waku/common/logging, waku/[
../../waku/factory/waku, common/logging,
../../waku/factory/external_config, factory/waku,
../../waku/node/health_monitor, factory/external_config,
../../waku/node/waku_metrics, node/health_monitor,
../../waku/waku_api/rest/builder as rest_server_builder, node/waku_metrics,
waku_api/rest/builder as rest_server_builder,
],
./tester_config, ./tester_config,
./lightpush_publisher, ./lightpush_publisher,
./filter_subscriber ./filter_subscriber

View File

@ -15,11 +15,13 @@ import
secp256k1, secp256k1,
json json
import import
../../waku/common/confutils/envvar/defs as confEnvvarDefs, waku/[
../../waku/common/confutils/envvar/std/net as confEnvvarNet, common/confutils/envvar/defs as confEnvvarDefs,
../../waku/common/logging, common/confutils/envvar/std/net as confEnvvarNet,
../../waku/factory/external_config, common/logging,
../../waku/waku_core factory/external_config,
waku/waku_core,
]
export confTomlDefs, confTomlNet, confEnvvarDefs, confEnvvarNet export confTomlDefs, confTomlNet, confEnvvarDefs, confEnvvarNet

View File

@ -18,16 +18,18 @@ import
metrics/chronos_httpserver, metrics/chronos_httpserver,
presto/[route, server, client] presto/[route, server, client]
import import
../../waku/waku_core, waku/[
../../waku/node/peer_manager, waku_core,
../../waku/waku_node, node/peer_manager,
../../waku/waku_enr, waku_node,
../../waku/discovery/waku_discv5, waku_enr,
../../waku/discovery/waku_dnsdisc, discovery/waku_discv5,
../../waku/waku_relay, discovery/waku_dnsdisc,
../../waku/waku_rln_relay, waku_relay,
../../waku/factory/builder, waku_rln_relay,
../../waku/factory/networks_config, factory/builder,
factory/networks_config,
],
./networkmonitor_metrics, ./networkmonitor_metrics,
./networkmonitor_config, ./networkmonitor_config,
./networkmonitor_utils ./networkmonitor_utils

View File

@ -1,3 +1,4 @@
-d:chronicles_line_numbers -d:chronicles_line_numbers
-d:chronicles_runtime_filtering:on -d:chronicles_runtime_filtering:on
-d:discv5_protocol_id:d5waku -d:discv5_protocol_id:d5waku
path = "../.."

View File

@ -1,3 +1,4 @@
-d:chronicles_line_numbers -d:chronicles_line_numbers
-d:chronicles_runtime_filtering:on -d:chronicles_runtime_filtering:on
-d:discv5_protocol_id:d5waku -d:discv5_protocol_id:d5waku
path = "../.."

View File

@ -12,11 +12,7 @@ import
libp2p/multicodec libp2p/multicodec
import import
./certsgenerator, ./certsgenerator,
../../waku/waku_enr, waku/[waku_enr, node/peer_manager, waku_core, waku_node, factory/builder]
../../waku/node/peer_manager,
../../waku/waku_core,
../../waku/waku_node,
../../waku/factory/builder
# protocols and their tag # protocols and their tag
const ProtocolsTable = { const ProtocolsTable = {

View File

@ -7,3 +7,4 @@
-d:chronicles_disabled_topics="eth,dnsdisc.client" -d:chronicles_disabled_topics="eth,dnsdisc.client"
# Results in empty output for some reason # Results in empty output for some reason
#-d:"chronicles_enabled_topics=GossipSub:TRACE,WakuRelay:TRACE" #-d:"chronicles_enabled_topics=GossipSub:TRACE,WakuRelay:TRACE"
path = "../.."

View File

@ -11,12 +11,14 @@ import
import import
../../tools/rln_keystore_generator/rln_keystore_generator, ../../tools/rln_keystore_generator/rln_keystore_generator,
../../tools/rln_db_inspector/rln_db_inspector, ../../tools/rln_db_inspector/rln_db_inspector,
../../waku/common/logging, waku/[
../../waku/factory/external_config, common/logging,
../../waku/factory/waku, factory/external_config,
../../waku/node/health_monitor, factory/waku,
../../waku/node/waku_metrics, node/health_monitor,
../../waku/waku_api/rest/builder as rest_server_builder node/waku_metrics,
waku_api/rest/builder as rest_server_builder,
]
logScope: logScope:
topics = "wakunode main" topics = "wakunode main"

View File

@ -2,11 +2,7 @@
## subscribe to messages without relay ## subscribe to messages without relay
import chronicles, chronos, stew/byteutils, stew/results import chronicles, chronos, stew/byteutils, stew/results
import import waku/[common/logging, node/peer_manager, waku_core, waku_filter_v2/client]
../../../waku/common/logging,
../../../waku/node/peer_manager,
../../../waku/waku_core,
../../../waku/waku_filter_v2/client
const const
FilterPeer = FilterPeer =

View File

@ -2,11 +2,7 @@
## use lightpush to publish messages without relay ## use lightpush to publish messages without relay
import chronicles, chronos, stew/byteutils, stew/results import chronicles, chronos, stew/byteutils, stew/results
import import waku/[common/logging, node/peer_manager, waku_core, waku_lightpush/client]
../../../waku/common/logging,
../../../waku/node/peer_manager,
../../../waku/waku_core,
../../../waku/waku_lightpush/client
const const
LightpushPeer = LightpushPeer =

View File

@ -2,3 +2,4 @@
-d:chronicles_log_level="DEBUG" -d:chronicles_log_level="DEBUG"
-d:chronicles_runtime_filtering=on -d:chronicles_runtime_filtering=on
-d:discv5_protocol_id="d5waku" -d:discv5_protocol_id="d5waku"
path = "../"

View File

@ -10,13 +10,15 @@ import
eth/p2p/discoveryv5/enr eth/p2p/discoveryv5/enr
import import
../../../waku/common/logging, waku/[
../../../waku/node/peer_manager, common/logging,
../../../waku/waku_core, node/peer_manager,
../../../waku/waku_node, waku_core,
../../../waku/waku_enr, waku_node,
../../../waku/discovery/waku_discv5, waku_enr,
../../../waku/factory/builder discovery/waku_discv5,
factory/builder,
]
proc now*(): Timestamp = proc now*(): Timestamp =
getNanosecondTime(getTime().toUnixFloat()) getNanosecondTime(getTime().toUnixFloat())

View File

@ -10,14 +10,16 @@ import
eth/p2p/discoveryv5/enr eth/p2p/discoveryv5/enr
import import
../../../waku/common/logging, waku/[
../../../waku/node/peer_manager, common/logging,
../../../waku/waku_core, node/peer_manager,
../../../waku/waku_node, waku_core,
../../../waku/waku_enr, waku_node,
../../../waku/discovery/waku_discv5, waku_enr,
../../../waku/factory/builder, discovery/waku_discv5,
../../../waku/waku_relay factory/builder,
waku_relay,
]
# An accesible bootstrap node. See waku.sandbox fleets.status.im # An accesible bootstrap node. See waku.sandbox fleets.status.im
const bootstrapNode = const bootstrapNode =

View File

@ -8,3 +8,4 @@
-d:chronicles_log_level=INFO -d:chronicles_log_level=INFO
# Results in empty output for some reason # Results in empty output for some reason
#-d:"chronicles_enabled_topics=GossipSub:TRACE,WakuRelay:TRACE" #-d:"chronicles_enabled_topics=GossipSub:TRACE,WakuRelay:TRACE"
path = "../../"

View File

@ -1,7 +1,7 @@
{.push raises: [].} {.push raises: [].}
import import
../../waku/common/logging, ../../waku/factory/[waku, networks_config, external_config] waku/[common/logging, factory/[waku, networks_config, external_config]]
import import
std/[options, strutils, os, sequtils], std/[options, strutils, os, sequtils],
stew/shims/net as stewNet, stew/shims/net as stewNet,

View File

@ -2,9 +2,9 @@
import import
stew/results, stew/results,
../../waku/common/logging, waku/[common/logging,
../../waku/waku_node, waku_node,
../../waku/waku_rln_relay, waku_rln_relay,],
./erc_5564_interface as StealthCommitmentFFI, ./erc_5564_interface as StealthCommitmentFFI,
./node_spec, ./node_spec,
./wire_spec ./wire_spec

View File

@ -1,7 +1,7 @@
import std/[times, options] import std/[times, options]
import confutils, chronicles, chronos, stew/results import confutils, chronicles, chronos, stew/results
import ../../waku/waku_core, ../../waku/common/protobuf import waku/[waku_core, common/protobuf]
import libp2p/protobuf/minprotobuf import libp2p/protobuf/minprotobuf
export export

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/strutils, stew/[results, byteutils], testutils/unittests import std/strutils, stew/[results, byteutils], testutils/unittests
import ../../waku/common/base64 import waku/common/base64
suite "Waku Common - stew base64 wrapper": suite "Waku Common - stew base64 wrapper":
const TestData = const TestData =

View File

@ -9,8 +9,8 @@ import
confutils/defs, confutils/defs,
confutils/std/net confutils/std/net
import import
../../waku/common/confutils/envvar/defs as confEnvvarDefs, waku/common/confutils/envvar/defs as confEnvvarDefs,
../../waku/common/confutils/envvar/std/net as confEnvvarNet waku/common/confutils/envvar/std/net as confEnvvarNet
type ConfResult[T] = Result[T, string] type ConfResult[T] = Result[T, string]

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/options, stew/results, stew/shims/net, testutils/unittests import std/options, stew/results, stew/shims/net, testutils/unittests
import ../../waku/common/enr, ../testlib/wakucore import waku/common/enr, ../testlib/wakucore
suite "nim-eth ENR - builder and typed record": suite "nim-eth ENR - builder and typed record":
test "Non-supported private key (ECDSA)": test "Non-supported private key (ECDSA)":

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import testutils/unittests import testutils/unittests
import ../../waku/common/envvar_serialization/utils import waku/common/envvar_serialization/utils
suite "nim-envvar-serialization - utils": suite "nim-envvar-serialization - utils":
test "construct env var key": test "construct env var key":

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import testutils/unittests, stew/results import testutils/unittests, stew/results
import ../../waku/common/utils/parse_size_units import waku/common/utils/parse_size_units
suite "Size serialization test": suite "Size serialization test":
test "parse normal sizes": test "parse normal sizes":

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import testutils/unittests import testutils/unittests
import ../../waku/common/protobuf import waku/common/protobuf
## Fixtures ## Fixtures

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/[strutils, os], stew/results, testutils/unittests import std/[strutils, os], stew/results, testutils/unittests
import ../../waku/common/databases/db_sqlite {.all.}, ../waku_archive/archive_utils import waku/common/databases/db_sqlite {.all.}, ../waku_archive/archive_utils
template sourceDir(): string = template sourceDir(): string =
currentSourcePath.rsplit(DirSep, 1)[0] currentSourcePath.rsplit(DirSep, 1)[0]

View File

@ -2,7 +2,7 @@
import testutils/unittests, chronos import testutils/unittests, chronos
import ../testlib/wakunode, ../../waku/factory/node_factory, ../../waku/waku_node import ../testlib/wakunode, waku/factory/node_factory, waku/waku_node
suite "Node Factory": suite "Node Factory":
test "Set up a node based on default configurations": test "Set up a node based on default configurations":

View File

@ -6,27 +6,20 @@ import
chronos, chronos,
libp2p/crypto/crypto libp2p/crypto/crypto
import import waku/incentivization/rpc, waku/incentivization/rpc_codec
../../../waku/incentivization/rpc,
../../../waku/incentivization/rpc_codec
suite "Waku Incentivization Eligibility Codec": suite "Waku Incentivization Eligibility Codec":
asyncTest "encode eligibility proof":
var byteSequence: seq[byte] = @[1, 2, 3, 4, 5, 6, 7, 8]
let epRpc = EligibilityProof(proofOfPayment: some(byteSequence))
let encoded = encode(epRpc)
let decoded = EligibilityProof.decode(encoded.buffer).get()
check:
epRpc == decoded
asyncTest "encode eligibility proof": asyncTest "encode eligibility status":
var byteSequence: seq[byte] = @[1, 2, 3, 4, 5, 6, 7, 8] let esRpc = EligibilityStatus(statusCode: uint32(200), statusDesc: some("OK"))
let epRpc = EligibilityProof(proofOfPayment: some(byteSequence)) let encoded = encode(esRpc)
let encoded = encode(epRpc) let decoded = EligibilityStatus.decode(encoded.buffer).get()
let decoded = EligibilityProof.decode(encoded.buffer).get() check:
check: esRpc == decoded
epRpc == decoded
asyncTest "encode eligibility status":
let esRpc = EligibilityStatus(
statusCode: uint32(200),
statusDesc: some("OK")
)
let encoded = encode(esRpc)
let decoded = EligibilityStatus.decode(encoded.buffer).get()
check:
esRpc == decoded

View File

@ -1,2 +1,3 @@
-d:chronicles_line_numbers -d:chronicles_line_numbers
-d:discv5_protocol_id=d5waku -d:discv5_protocol_id=d5waku
path = "../"

View File

@ -1,13 +1,13 @@
import std/[options], stew/results, testutils/unittests import std/[options], stew/results, testutils/unittests
import import
../../../../waku/[node/peer_manager/peer_store/migrations], waku/node/peer_manager/peer_store/migrations,
../../waku_archive/archive_utils, ../../waku_archive/archive_utils,
../../testlib/[simple_mock] ../../testlib/[simple_mock]
import std/[tables, strutils, os], stew/results, chronicles import std/[tables, strutils, os], stew/results, chronicles
import ../../../../waku/[common/databases/db_sqlite, common/databases/common] import waku/common/databases/db_sqlite, waku/common/databases/common
suite "Migrations": suite "Migrations":
test "migrate ok": test "migrate ok":

View File

@ -1,8 +1,6 @@
import stew/results, testutils/unittests import stew/results, testutils/unittests
import import waku/node/peer_manager/peer_store/peer_storage, waku/waku_core/peers
../../../../waku/node/peer_manager/peer_store/peer_storage,
../../../../waku/waku_core/peers
suite "PeerStorage": suite "PeerStorage":
var peerStorage {.threadvar.}: PeerStorage var peerStorage {.threadvar.}: PeerStorage

View File

@ -8,9 +8,7 @@ import
eth/p2p/discoveryv5/enr, eth/p2p/discoveryv5/enr,
nimcrypto/utils nimcrypto/utils
import import waku/waku_core/peers, waku/node/peer_manager/peer_store/waku_peer_storage
../../../../waku/waku_core/peers,
../../../../waku/node/peer_manager/peer_store/waku_peer_storage
proc `==`(a, b: RemotePeerInfo): bool = proc `==`(a, b: RemotePeerInfo): bool =
let comparisons = let comparisons =

View File

@ -1,7 +1,7 @@
import std/options, stew/results, libp2p/peerstore import std/options, stew/results, libp2p/peerstore
import import
../../../../waku/node/peer_manager/[waku_peer_store, peer_store/waku_peer_storage], waku/node/peer_manager/[waku_peer_store, peer_store/waku_peer_storage],
../../../waku_archive/archive_utils ../../../waku_archive/archive_utils
proc newTestWakuPeerStorage*(path: Option[string] = string.none()): WakuPeerStorage = proc newTestWakuPeerStorage*(path: Option[string] = string.none()): WakuPeerStorage =

View File

@ -6,10 +6,11 @@ import
testutils/unittests testutils/unittests
import import
../../../waku/[node/waku_node, waku_core], waku/node/waku_node,
waku/waku_core,
../../waku_lightpush/[lightpush_utils], ../../waku_lightpush/[lightpush_utils],
../../testlib/[wakucore, wakunode, futures, testasync], ../../testlib/[wakucore, wakunode, futures, testasync],
../../../../waku/node/peer_manager/peer_manager waku/node/peer_manager/peer_manager
suite "Peer Manager": suite "Peer Manager":
suite "onPeerMetadata": suite "onPeerMetadata":

View File

@ -10,7 +10,7 @@ import
libp2p/[peerstore, crypto/crypto] libp2p/[peerstore, crypto/crypto]
import import
../../../waku/[ waku/[
waku_core, waku_core,
node/peer_manager, node/peer_manager,
node/waku_node, node/waku_node,

View File

@ -8,7 +8,7 @@ import
libp2p/crypto/crypto libp2p/crypto/crypto
import import
../../../waku/[ waku/[
common/paging, common/paging,
node/waku_node, node/waku_node,
node/peer_manager, node/peer_manager,

View File

@ -11,7 +11,7 @@ import
libp2p/[peerstore, crypto/crypto] libp2p/[peerstore, crypto/crypto]
import import
../../../waku/[ waku/[
waku_core, waku_core,
node/peer_manager, node/peer_manager,
node/waku_node, node/waku_node,
@ -23,7 +23,7 @@ import
waku_lightpush/client, waku_lightpush/client,
waku_lightpush/protocol_metrics, waku_lightpush/protocol_metrics,
waku_lightpush/rpc, waku_lightpush/rpc,
waku_rln_relay waku_rln_relay,
], ],
../testlib/[assertions, common, wakucore, wakunode, testasync, futures, testutils], ../testlib/[assertions, common, wakucore, wakunode, testasync, futures, testutils],
../resources/payloads ../resources/payloads
@ -91,11 +91,10 @@ suite "Waku Lightpush - End To End":
suite "Waku LightPush Validation Tests": suite "Waku LightPush Validation Tests":
asyncTest "Validate message size exceeds limit": asyncTest "Validate message size exceeds limit":
let let msgOverLimit = fakeWakuMessage(
msgOverLimit = fakeWakuMessage( contentTopic = contentTopic,
contentTopic = contentTopic, payload = getByteSequence(DefaultMaxWakuMessageSize + 64 * 1024),
payload = getByteSequence(DefaultMaxWakuMessageSize + 64 * 1024), )
)
# When the client publishes an over-limit message # When the client publishes an over-limit message
let publishResponse = await client.lightpushPublish( let publishResponse = await client.lightpushPublish(
@ -104,7 +103,8 @@ suite "Waku Lightpush - End To End":
check: check:
publishResponse.isErr() publishResponse.isErr()
publishResponse.error == fmt"Message size exceeded maximum of {DefaultMaxWakuMessageSize} bytes" publishResponse.error ==
fmt"Message size exceeded maximum of {DefaultMaxWakuMessageSize} bytes"
suite "RLN Proofs as a Lightpush Service": suite "RLN Proofs as a Lightpush Service":
var var
@ -143,7 +143,6 @@ suite "RLN Proofs as a Lightpush Service":
rlnRelayTreePath: genTempPath("rln_tree", "wakunode"), rlnRelayTreePath: genTempPath("rln_tree", "wakunode"),
) )
await allFutures(server.start(), client.start()) await allFutures(server.start(), client.start())
await server.start() await server.start()

View File

@ -13,7 +13,7 @@ import
eth/p2p/discoveryv5/enr eth/p2p/discoveryv5/enr
import import
../../../waku/[ waku/[
waku_node, waku_node,
discovery/waku_discv5, discovery/waku_discv5,
waku_peer_exchange, waku_peer_exchange,

View File

@ -13,7 +13,7 @@ import
from times import getTime, toUnix from times import getTime, toUnix
import import
../../../waku/[ waku/[
waku_core, waku_core,
node/peer_manager, node/peer_manager,
node/waku_node, node/waku_node,

View File

@ -12,8 +12,7 @@ import
from std/times import epochTime from std/times import epochTime
import import
../../../waku/ waku/[node/waku_node, node/peer_manager, waku_core, waku_node, waku_rln_relay],
[node/waku_node, node/peer_manager, waku_core, waku_node, waku_rln_relay],
../waku_store/store_utils, ../waku_store/store_utils,
../waku_archive/archive_utils, ../waku_archive/archive_utils,
../waku_relay/utils, ../waku_relay/utils,

View File

@ -17,7 +17,7 @@ import
libp2p/protocols/pubsub/pubsub libp2p/protocols/pubsub/pubsub
import import
../../../waku/[ waku/[
waku_core/topics/pubsub_topic, waku_core/topics/pubsub_topic,
waku_core/topics/sharding, waku_core/topics/sharding,
node/waku_node, node/waku_node,
@ -31,7 +31,7 @@ import
../waku_archive/archive_utils, ../waku_archive/archive_utils,
../testlib/[assertions, common, wakucore, wakunode, testasync, futures, testutils] ../testlib/[assertions, common, wakucore, wakunode, testasync, futures, testutils]
import ../../../waku/waku_relay/protocol import waku_relay/protocol
const const
listenIp = ValidIpAddress.init("0.0.0.0") listenIp = ValidIpAddress.init("0.0.0.0")

View File

@ -8,7 +8,7 @@ import
libp2p/crypto/crypto libp2p/crypto/crypto
import import
../../../waku/[ waku/[
common/paging, common/paging,
node/waku_node, node/waku_node,
node/peer_manager, node/peer_manager,

View File

@ -1,7 +1,6 @@
import std/options, results import std/options, results
import import
../../../waku/ waku/[node/peer_manager, node/waku_node, waku_enr/sharding, common/enr/typed_record],
[node/peer_manager, node/waku_node, waku_enr/sharding, common/enr/typed_record],
../testlib/[wakucore] ../testlib/[wakucore]
proc relayShards*(node: WakuNode): RelayShards = proc relayShards*(node: WakuNode): RelayShards =

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/[sets, random], stew/[results, byteutils], testutils/unittests import std/[sets, random], stew/[results, byteutils], testutils/unittests
import ../../waku/waku_core, ../../waku/waku_api/message_cache, ./testlib/wakucore import waku/waku_core, waku/waku_api/message_cache, ./testlib/wakucore
randomize() randomize()

View File

@ -17,18 +17,20 @@ import
libp2p/protocols/pubsub/rpc/message, libp2p/protocols/pubsub/rpc/message,
libp2p/peerid libp2p/peerid
import import
../../waku/common/databases/db_sqlite, waku/[
../../waku/node/peer_manager/peer_manager, common/databases/db_sqlite,
../../waku/node/peer_manager/peer_store/waku_peer_storage, node/peer_manager/peer_manager,
../../waku/waku_node, node/peer_manager/peer_store/waku_peer_storage,
../../waku/waku_core, waku_node,
../../waku/waku_enr/capabilities, waku_core,
../../waku/waku_relay/protocol, waku_enr/capabilities,
../../waku/waku_filter_v2/common, waku_relay/protocol,
../../waku/waku_store/common, waku_filter_v2/common,
../../waku/waku_lightpush/common, waku_store/common,
../../waku/waku_peer_exchange, waku_lightpush/common,
../../waku/waku_metadata, waku_peer_exchange,
waku_metadata,
],
./testlib/common, ./testlib/common,
./testlib/testutils, ./testlib/testutils,
./testlib/wakucore, ./testlib/wakucore,

View File

@ -2,10 +2,12 @@
import std/options, testutils/unittests, eth/p2p/discoveryv5/enr, libp2p/crypto/crypto import std/options, testutils/unittests, eth/p2p/discoveryv5/enr, libp2p/crypto/crypto
import import
../../waku/common/databases/db_sqlite, waku/[
../../waku/node/peer_manager/peer_manager, common/databases/db_sqlite,
../../waku/node/peer_manager/peer_store/waku_peer_storage, node/peer_manager/peer_manager,
../../waku/waku_enr, node/peer_manager/peer_store/waku_peer_storage,
waku_enr,
],
./testlib/wakucore ./testlib/wakucore
suite "Peer Storage": suite "Peer Storage":

View File

@ -9,9 +9,7 @@ import
libp2p/multiaddress, libp2p/multiaddress,
testutils/unittests testutils/unittests
import import
../../waku/node/peer_manager/peer_manager, waku/[node/peer_manager/peer_manager, node/peer_manager/waku_peer_store, waku_node],
../../waku/node/peer_manager/waku_peer_store,
../../waku/waku_node,
./testlib/wakucore ./testlib/wakucore
suite "Extended nim-libp2p Peer Store": suite "Extended nim-libp2p Peer Store":

View File

@ -10,8 +10,7 @@ import
libp2p/crypto/crypto, libp2p/crypto/crypto,
libp2p/protocols/pubsub/gossipsub libp2p/protocols/pubsub/gossipsub
import import waku/waku_core, waku/waku_node, ./testlib/wakucore, ./testlib/wakunode
../../waku/waku_core, ../../waku/waku_node, ./testlib/wakucore, ./testlib/wakunode
procSuite "Relay (GossipSub) Peer Exchange": procSuite "Relay (GossipSub) Peer Exchange":
asyncTest "Mount relay without peer exchange handler": asyncTest "Mount relay without peer exchange handler":

View File

@ -1,11 +1,7 @@
{.used.} {.used.}
import testutils/unittests import testutils/unittests
import import stew/results, waku/waku_core/message, waku/waku_core/time, ./testlib/common
stew/results,
../../waku/waku_core/message,
../../waku/waku_core/time,
./testlib/common
suite "Waku Payload": suite "Waku Payload":
test "Encode/Decode waku message with timestamp": test "Encode/Decode waku message with timestamp":

View File

@ -11,9 +11,9 @@ import
eth/keys, eth/keys,
dnsdisc/builder dnsdisc/builder
import import
../../waku/node/peer_manager, waku/node/peer_manager,
../../waku/waku_node, waku/waku_node,
../../waku/discovery/waku_dnsdisc, waku/discovery/waku_dnsdisc,
./testlib/common, ./testlib/common,
./testlib/wakucore, ./testlib/wakucore,
./testlib/wakunode ./testlib/wakunode

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/[options, sequtils], stew/results, testutils/unittests import std/[options, sequtils], stew/results, testutils/unittests
import ../../waku/waku_core, ../../waku/waku_enr, ./testlib/wakucore import waku/waku_core, waku/waku_enr, ./testlib/wakucore
suite "Waku ENR - Capabilities bitfield": suite "Waku ENR - Capabilities bitfield":
test "check capabilities support": test "check capabilities support":

View File

@ -11,8 +11,7 @@ import
libp2p/stream/bufferstream, libp2p/stream/bufferstream,
libp2p/stream/connection, libp2p/stream/connection,
libp2p/crypto/crypto libp2p/crypto/crypto
import import waku/waku_core, waku/waku_node, ./testlib/wakucore, ./testlib/wakunode
../../waku/waku_core, ../../waku/waku_node, ./testlib/wakucore, ./testlib/wakunode
suite "Waku Keepalive": suite "Waku Keepalive":
asyncTest "handle ping keepalives": asyncTest "handle ping keepalives":

View File

@ -1,9 +1,9 @@
{.used.} {.used.}
import std/[os, json], chronos, testutils/unittests import std/[os, json], chronos, testutils/unittests
import ../../waku/waku_keystore, ./testlib/common import waku/waku_keystore, ./testlib/common
from ../../waku/waku_noise/noise_utils import randomSeqByte from waku/waku_noise/noise_utils import randomSeqByte
procSuite "Credentials test suite": procSuite "Credentials test suite":
let testAppInfo = AppInfo(application: "test", appIdentifier: "1234", version: "0.1") let testAppInfo = AppInfo(application: "test", appIdentifier: "1234", version: "0.1")

View File

@ -1,9 +1,9 @@
{.used.} {.used.}
import std/[json, os], stew/byteutils, testutils/unittests, chronos, eth/keys import std/[json, os], stew/byteutils, testutils/unittests, chronos, eth/keys
import ../../waku/waku_keystore, ./testlib/common import waku/waku_keystore, ./testlib/common
from ../../waku/waku_noise/noise_utils import randomSeqByte from waku/waku_noise/noise_utils import randomSeqByte
suite "KeyFile test suite": suite "KeyFile test suite":
test "Create/Save/Load single keyfile": test "Create/Save/Load single keyfile":

View File

@ -14,11 +14,14 @@ import
eth/keys, eth/keys,
eth/p2p/discoveryv5/enr eth/p2p/discoveryv5/enr
import import
../../waku/waku_node, waku/
../../waku/waku_core/topics, [
../../waku/node/peer_manager, waku_node,
../../waku/discovery/waku_discv5, waku_core/topics,
../../waku/waku_metadata, node/peer_manager,
discovery/waku_discv5,
waku_metadata,
],
./testlib/wakucore, ./testlib/wakucore,
./testlib/wakunode ./testlib/wakunode

View File

@ -2,9 +2,9 @@
import chronos, confutils/toml/std/net, libp2p/multiaddress, testutils/unittests import chronos, confutils/toml/std/net, libp2p/multiaddress, testutils/unittests
import ./testlib/wakunode, ../../waku/waku_enr/capabilities import ./testlib/wakunode, waku/waku_enr/capabilities
include ../../waku/node/config include waku/node/config
proc defaultTestWakuFlags(): CapabilitiesBitfield = proc defaultTestWakuFlags(): CapabilitiesBitfield =
CapabilitiesBitfield.init( CapabilitiesBitfield.init(

View File

@ -9,12 +9,14 @@ import
libp2p/protobuf/minprotobuf, libp2p/protobuf/minprotobuf,
stew/endians2 stew/endians2
import import
../../waku/utils/noise as waku_message_utils, waku/[
../../waku/waku_noise/noise_types, utils/noise as waku_message_utils,
../../waku/waku_noise/noise_utils, waku_noise/noise_types,
../../waku/waku_noise/noise, waku_noise/noise_utils,
../../waku/waku_noise/noise_handshake_processing, waku_noise/noise,
../../waku/waku_core, waku_noise/noise_handshake_processing,
waku_core,
],
./testlib/common ./testlib/common
procSuite "Waku Noise": procSuite "Waku Noise":

View File

@ -2,12 +2,14 @@
import std/tables, stew/[results, byteutils], testutils/unittests import std/tables, stew/[results, byteutils], testutils/unittests
import import
../../waku/common/protobuf, waku/[
../../waku/utils/noise as waku_message_utils, common/protobuf,
../../waku/waku_noise/noise_types, utils/noise as waku_message_utils,
../../waku/waku_noise/noise_utils, waku_noise/noise_types,
../../waku/waku_noise/noise_handshake_processing, waku_noise/noise_utils,
../../waku/waku_core, waku_noise/noise_handshake_processing,
waku_core,
],
./testlib/common ./testlib/common
procSuite "Waku Noise Sessions": procSuite "Waku Noise Sessions":

View File

@ -2,10 +2,7 @@
import std/[options, sequtils, tables], testutils/unittests, chronos, chronicles import std/[options, sequtils, tables], testutils/unittests, chronos, chronicles
import import
../../waku/waku_metadata, waku/waku_metadata, waku/waku_metadata/rpc, ./testlib/wakucore, ./testlib/wakunode
../../waku/waku_metadata/rpc,
./testlib/wakucore,
./testlib/wakunode
procSuite "Waku Protobufs": procSuite "Waku Protobufs":
# TODO: Missing test coverage in many encode/decode protobuf functions # TODO: Missing test coverage in many encode/decode protobuf functions

View File

@ -2,7 +2,7 @@
import chronos, testutils/unittests, libp2p, libp2p/protocols/rendezvous import chronos, testutils/unittests, libp2p, libp2p/protocols/rendezvous
import ../../waku/node/waku_switch, ./testlib/common, ./testlib/wakucore import waku/node/waku_switch, ./testlib/common, ./testlib/wakucore
proc newRendezvousClientSwitch(rdv: RendezVous): Switch = proc newRendezvousClientSwitch(rdv: RendezVous): Switch =
SwitchBuilder SwitchBuilder

View File

@ -8,7 +8,7 @@ import
libp2p/protocols/connectivity/relay/relay, libp2p/protocols/connectivity/relay/relay,
libp2p/protocols/connectivity/relay/client, libp2p/protocols/connectivity/relay/client,
stew/byteutils stew/byteutils
import ../../waku/node/waku_switch, ./testlib/common, ./testlib/wakucore import waku/node/waku_switch, ./testlib/common, ./testlib/wakucore
proc newCircuitRelayClientSwitch(relayClient: RelayClient): Switch = proc newCircuitRelayClientSwitch(relayClient: RelayClient): Switch =
SwitchBuilder SwitchBuilder

View File

@ -17,11 +17,7 @@ import
libp2p/nameresolving/mockresolver, libp2p/nameresolving/mockresolver,
eth/p2p/discoveryv5/enr eth/p2p/discoveryv5/enr
import import
../../waku/waku_core, waku/[waku_core, waku_node, node/peer_manager, waku_relay, waku_peer_exchange],
../../waku/waku_node,
../../waku/node/peer_manager,
../../waku/waku_relay,
../../waku/waku_peer_exchange,
./testlib/wakucore, ./testlib/wakucore,
./testlib/wakunode ./testlib/wakunode

View File

@ -2,10 +2,7 @@
import std/options, stew/shims/net as stewNet, testutils/unittests, chronos import std/options, stew/shims/net as stewNet, testutils/unittests, chronos
import import
../../waku/waku_core, waku/[waku_core, waku_lightpush/common, node/peer_manager, waku_node],
../../waku/waku_lightpush/common,
../../waku/node/peer_manager,
../../waku/waku_node,
./testlib/wakucore, ./testlib/wakucore,
./testlib/wakunode ./testlib/wakunode

View File

@ -1,6 +1,6 @@
import chronos import chronos
import ../../../waku/[waku_core/message, waku_store, waku_store_legacy] import waku/[waku_core/message, waku_store, waku_store_legacy]
const const
FUTURE_TIMEOUT* = 1.seconds FUTURE_TIMEOUT* = 1.seconds

View File

@ -1,9 +1,11 @@
import chronicles, chronos import chronicles, chronos
import import
../../../waku/waku_archive, waku/[
../../../waku/waku_archive/driver as driver_module, waku_archive,
../../../waku/waku_archive/driver/builder, waku_archive/driver as driver_module,
../../../waku/waku_archive/driver/postgres_driver waku_archive/driver/builder,
waku_archive/driver/postgres_driver,
]
const storeMessageDbUrl = "postgres://postgres:test123@localhost:5432/postgres" const storeMessageDbUrl = "postgres://postgres:test123@localhost:5432/postgres"

View File

@ -1,6 +1,6 @@
import std/[tables, sequtils, options] import std/[tables, sequtils, options]
import ../../../waku/waku_core/topics, ../testlib/wakucore import waku/waku_core/topics, ../testlib/wakucore
proc `==`*( proc `==`*(
table: Table[pubsub_topic.NsPubsubTopic, seq[NsContentTopic]], table: Table[pubsub_topic.NsPubsubTopic, seq[NsContentTopic]],

View File

@ -7,7 +7,7 @@ import
libp2p/builders, libp2p/builders,
libp2p/crypto/crypto as libp2p_keys, libp2p/crypto/crypto as libp2p_keys,
eth/keys as eth_keys eth/keys as eth_keys
import ../../../waku/waku_core, ./common import waku/waku_core, ./common
export switch export switch

View File

@ -9,14 +9,16 @@ import
libp2p/crypto/crypto as libp2p_keys, libp2p/crypto/crypto as libp2p_keys,
eth/keys as eth_keys eth/keys as eth_keys
import import
../../../waku/waku_node, waku/[
../../../waku/waku_core/topics, waku_node,
../../../waku/node/peer_manager, waku_core/topics,
../../../waku/waku_enr, node/peer_manager,
../../../waku/discovery/waku_discv5, waku_enr,
../../../waku/factory/external_config, discovery/waku_discv5,
../../../waku/factory/internal_config, factory/external_config,
../../../waku/factory/builder, factory/internal_config,
factory/builder,
],
./common ./common
# Waku node # Waku node

View File

@ -3,7 +3,7 @@
import std/options, stew/results, chronos, libp2p/crypto/crypto import std/options, stew/results, chronos, libp2p/crypto/crypto
import import
../../../waku/[ waku/[
node/peer_manager, node/peer_manager,
waku_core, waku_core,
waku_archive, waku_archive,

View File

@ -2,10 +2,12 @@
import std/[sequtils, options], testutils/unittests, chronos import std/[sequtils, options], testutils/unittests, chronos
import import
../../../waku/waku_archive, waku/[
../../../waku/waku_archive/driver/postgres_driver, waku_archive,
../../../waku/waku_core, waku_archive/driver/postgres_driver,
../../../waku/waku_core/message/digest, waku_core,
waku_core/message/digest,
],
../testlib/wakucore, ../testlib/wakucore,
../testlib/testasync, ../testlib/testasync,
../testlib/postgres ../testlib/postgres

View File

@ -6,11 +6,13 @@ import
chronos, chronos,
chronicles chronicles
import import
../../../waku/waku_archive, waku/[
../../../waku/waku_archive/driver as driver_module, waku_archive,
../../../waku/waku_archive/driver/postgres_driver, waku_archive/driver as driver_module,
../../../waku/waku_core, waku_archive/driver/postgres_driver,
../../../waku/waku_core/message/digest, waku_core,
waku_core/message/digest,
],
../testlib/common, ../testlib/common,
../testlib/wakucore, ../testlib/wakucore,
../testlib/testasync, ../testlib/testasync,

View File

@ -2,10 +2,12 @@
import std/options, stew/results, testutils/unittests import std/options, stew/results, testutils/unittests
import import
../../../waku/waku_archive, waku/[
../../../waku/waku_archive/driver/queue_driver/queue_driver {.all.}, waku_archive,
../../../waku/waku_archive/driver/queue_driver/index, waku_archive/driver/queue_driver/queue_driver {.all.},
../../../waku/waku_core waku_archive/driver/queue_driver/index,
waku_core,
]
# Helper functions # Helper functions

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/[times, random], stew/byteutils, testutils/unittests, nimcrypto import std/[times, random], stew/byteutils, testutils/unittests, nimcrypto
import ../../../waku/waku_core, ../../../waku/waku_archive/driver/queue_driver/index import waku/waku_core, waku/waku_archive/driver/queue_driver/index
var rng = initRand() var rng = initRand()

View File

@ -3,10 +3,12 @@
import import
std/[options, sequtils, algorithm], testutils/unittests, libp2p/protobuf/minprotobuf std/[options, sequtils, algorithm], testutils/unittests, libp2p/protobuf/minprotobuf
import import
../../../waku/waku_archive, waku/[
../../../waku/waku_archive/driver/queue_driver/queue_driver {.all.}, waku_archive,
../../../waku/waku_archive/driver/queue_driver/index, waku_archive/driver/queue_driver/queue_driver {.all.},
../../../waku/waku_core, waku_archive/driver/queue_driver/index,
waku_core,
],
../testlib/common, ../testlib/common,
../testlib/wakucore ../testlib/wakucore

View File

@ -3,10 +3,13 @@
import import
std/[options, sequtils, random, algorithm], testutils/unittests, chronos, chronicles std/[options, sequtils, random, algorithm], testutils/unittests, chronos, chronicles
import import
../../../waku/waku_archive, waku/
../../../waku/waku_archive/driver/queue_driver, [
../../../waku/waku_core, waku_archive,
../../../waku/waku_core/message/digest, waku_archive/driver/queue_driver,
waku_core,
waku_core/message/digest,
],
../testlib/common, ../testlib/common,
../testlib/wakucore ../testlib/wakucore

View File

@ -2,10 +2,12 @@
import std/sequtils, testutils/unittests, chronos import std/sequtils, testutils/unittests, chronos
import import
../../../waku/common/databases/db_sqlite, waku/[
../../../waku/waku_archive, common/databases/db_sqlite,
../../../waku/waku_archive/driver/sqlite_driver, waku_archive,
../../../waku/waku_core, waku_archive/driver/sqlite_driver,
waku_core,
],
../waku_archive/archive_utils, ../waku_archive/archive_utils,
../testlib/common, ../testlib/common,
../testlib/wakucore ../testlib/wakucore

View File

@ -4,11 +4,13 @@ import
std/[options, sequtils, random, algorithm], testutils/unittests, chronos, chronicles std/[options, sequtils, random, algorithm], testutils/unittests, chronos, chronicles
import import
../../../waku/common/databases/db_sqlite, waku/[
../../../waku/waku_archive, common/databases/db_sqlite,
../../../waku/waku_archive/driver/sqlite_driver, waku_archive,
../../../waku/waku_core, waku_archive/driver/sqlite_driver,
../../../waku/waku_core/message/digest, waku_core,
waku_core/message/digest,
],
../testlib/common, ../testlib/common,
../testlib/wakucore, ../testlib/wakucore,
../waku_archive/archive_utils ../waku_archive/archive_utils

View File

@ -1,9 +1,7 @@
{.used.} {.used.}
import testutils/unittests, chronos import testutils/unittests, chronos
import import waku/waku_archive/driver/postgres_driver/partitions_manager, waku/waku_core/time
../../../waku/waku_archive/driver/postgres_driver/partitions_manager,
../../../waku/waku_core/time
suite "Partition Manager": suite "Partition Manager":
test "Calculate end partition time": test "Calculate end partition time":

View File

@ -2,14 +2,16 @@
import std/[sequtils, times], stew/results, testutils/unittests, chronos import std/[sequtils, times], stew/results, testutils/unittests, chronos
import import
../../../waku/common/databases/db_sqlite, waku/[
../../../waku/waku_core, common/databases/db_sqlite,
../../../waku/waku_core/message/digest, waku_core,
../../../waku/waku_archive, waku_core/message/digest,
../../../waku/waku_archive/driver/sqlite_driver, waku_archive,
../../../waku/waku_archive/retention_policy, waku_archive/driver/sqlite_driver,
../../../waku/waku_archive/retention_policy/retention_policy_capacity, waku_archive/retention_policy,
../../../waku/waku_archive/retention_policy/retention_policy_size, waku_archive/retention_policy/retention_policy_capacity,
waku_archive/retention_policy/retention_policy_size,
],
../waku_archive/archive_utils, ../waku_archive/archive_utils,
../testlib/common, ../testlib/common,
../testlib/wakucore ../testlib/wakucore

View File

@ -8,12 +8,14 @@ import
libp2p/crypto/crypto libp2p/crypto/crypto
import import
../../../waku/common/databases/db_sqlite, waku/[
../../../waku/common/paging, common/databases/db_sqlite,
../../../waku/waku_core, common/paging,
../../../waku/waku_core/message/digest, waku_core,
../../../waku/waku_archive/driver/sqlite_driver, waku_core/message/digest,
../../../waku/waku_archive, waku_archive/driver/sqlite_driver,
waku_archive,
],
../waku_archive/archive_utils, ../waku_archive/archive_utils,
../testlib/common, ../testlib/common,
../testlib/wakucore ../testlib/wakucore

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/sequtils, stew/byteutils, stew/endians2, testutils/unittests import std/sequtils, stew/byteutils, stew/endians2, testutils/unittests
import ../../../waku/waku_core, ../testlib/wakucore import waku/waku_core, ../testlib/wakucore
suite "Waku Message - Deterministic hashing": suite "Waku Message - Deterministic hashing":
test "digest computation - empty meta field": test "digest computation - empty meta field":

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import std/options, stew/results, testutils/unittests import std/options, stew/results, testutils/unittests
import ../../../waku/waku_core/topics import waku/waku_core/topics
suite "Waku Message - Content topics namespacing": suite "Waku Message - Content topics namespacing":
test "Stringify namespaced content topic": test "Stringify namespaced content topic":

View File

@ -2,7 +2,7 @@
import import
stew/results, testutils/unittests, libp2p/multiaddress, libp2p/peerid, libp2p/errors stew/results, testutils/unittests, libp2p/multiaddress, libp2p/peerid, libp2p/errors
import ../../waku/waku_core import waku/waku_core
suite "Waku Core - Peers": suite "Waku Core - Peers":
test "Peer info parses correctly": test "Peer info parses correctly":

View File

@ -1,7 +1,7 @@
{.used.} {.used.}
import testutils/unittests import testutils/unittests
import ../../waku/waku_core/time import waku/waku_core/time
suite "Waku Core - Time": suite "Waku Core - Time":
test "Test timestamp conversion": test "Test timestamp conversion":

View File

@ -2,7 +2,7 @@
import std/[options], testutils/unittests, results import std/[options], testutils/unittests, results
import ../../../../waku/[waku_core/topics/pubsub_topic], ../../testlib/[wakucore] import waku/waku_core/topics/pubsub_topic, ../../testlib/[wakucore]
suite "Static Sharding Functionality": suite "Static Sharding Functionality":
test "Shard Cluster Identification": test "Shard Cluster Identification":

View File

@ -1,6 +1,6 @@
import std/[options, tables], testutils/unittests import std/[options, tables], testutils/unittests
import ../../../../waku/waku_core/topics, ../../testlib/[wakucore, tables, testutils] import waku/waku_core/topics, ../../testlib/[wakucore, tables, testutils]
const GenerationZeroShardsCount = 8 const GenerationZeroShardsCount = 8
const ClusterId = 1 const ClusterId = 1

View File

@ -11,7 +11,7 @@ import
eth/keys as eth_keys eth/keys as eth_keys
import import
../../../waku/[waku_core/topics, waku_enr, discovery/waku_discv5, common/enr], waku/[waku_core/topics, waku_enr, discovery/waku_discv5, common/enr],
../testlib/[wakucore, testasync, assertions, futures], ../testlib/[wakucore, testasync, assertions, futures],
../waku_enr/utils, ../waku_enr/utils,
./utils ./utils

View File

@ -6,7 +6,7 @@ import
eth/keys as eth_keys eth/keys as eth_keys
import import
../../../waku/ waku/
[waku_core/topics, waku_enr, discovery/waku_discv5, node/peer_manager/peer_manager], [waku_core/topics, waku_enr, discovery/waku_discv5, node/peer_manager/peer_manager],
../testlib/[common, wakucore] ../testlib/[common, wakucore]

View File

@ -9,7 +9,7 @@ import
eth/keys as eth_keys eth/keys as eth_keys
import import
../../../waku/[waku_enr, discovery/waku_discv5, waku_core, common/enr], waku/[waku_enr, discovery/waku_discv5, waku_core, common/enr],
../testlib/wakucore, ../testlib/wakucore,
../waku_discv5/utils, ../waku_discv5/utils,
./utils ./utils

View File

@ -7,7 +7,7 @@ import
eth/keys as eth_keys eth/keys as eth_keys
import import
../../../waku/[waku_core/topics, waku_enr, discovery/waku_discv5, waku_enr/sharding], waku/[waku_core/topics, waku_enr, discovery/waku_discv5, waku_enr/sharding],
../testlib/[common, wakucore] ../testlib/[common, wakucore]
proc newTestEnrRecord*( proc newTestEnrRecord*(

View File

@ -10,8 +10,9 @@ import
libp2p/peerstore libp2p/peerstore
import import
../../../waku/[node/peer_manager, waku_core], waku/node/peer_manager,
../../../waku/waku_filter_v2/[common, client, subscriptions, protocol, rpc_codec], waku/waku_core,
waku/waku_filter_v2/[common, client, subscriptions, protocol, rpc_codec],
../testlib/[wakucore, testasync, testutils, futures, sequtils], ../testlib/[wakucore, testasync, testutils, futures, sequtils],
./waku_filter_utils, ./waku_filter_utils,
../resources/payloads ../resources/payloads

View File

@ -7,11 +7,13 @@ import
chronicles, chronicles,
libp2p/peerstore libp2p/peerstore
import import
../../../waku/node/peer_manager, waku/[
../../../waku/waku_filter_v2, node/peer_manager,
../../../waku/waku_filter_v2/rpc, waku_filter_v2,
../../../waku/waku_filter_v2/subscriptions, waku_filter_v2/rpc,
../../../waku/waku_core, waku_filter_v2/subscriptions,
waku_core,
],
../testlib/common, ../testlib/common,
../testlib/wakucore, ../testlib/wakucore,
./waku_filter_utils ./waku_filter_utils

View File

@ -1,7 +1,7 @@
import std/[options, tables, sets, sequtils, algorithm], chronos, chronicles, os import std/[options, tables, sets, sequtils, algorithm], chronos, chronicles, os
import import
../../../waku/[ waku/[
node/peer_manager, node/peer_manager,
waku_filter_v2, waku_filter_v2,
waku_filter_v2/client, waku_filter_v2/client,

View File

@ -3,10 +3,10 @@
import std/options, chronicles, chronos, libp2p/crypto/crypto import std/options, chronicles, chronos, libp2p/crypto/crypto
import import
../../waku/node/peer_manager, waku/node/peer_manager,
../../waku/waku_core, waku/waku_core,
../../waku/waku_lightpush, waku/waku_lightpush,
../../waku/waku_lightpush/[client, common], waku/waku_lightpush/[client, common],
../testlib/[common, wakucore] ../testlib/[common, wakucore]
proc newTestWakuLightpushNode*( proc newTestWakuLightpushNode*(

Some files were not shown because too many files have changed in this diff Show More