From a60f2e529cf160851b960f2aeda0240eb736ab86 Mon Sep 17 00:00:00 2001 From: "fryorcraken.eth" Date: Wed, 9 Nov 2022 14:47:13 +1100 Subject: [PATCH] test: remove todo now that @multiformats/multiaddr@11 is used by all deps --- packages/tests/tests/enr.node.spec.ts | 6 ----- packages/tests/tests/filter.node.spec.ts | 2 -- packages/tests/tests/light_push.node.spec.ts | 4 ---- packages/tests/tests/relay.node.spec.ts | 15 ------------- packages/tests/tests/store.node.spec.ts | 22 ------------------- .../tests/wait_for_remote_peer.node.spec.ts | 16 -------------- packages/tests/tests/waku.node.spec.ts | 9 -------- 7 files changed, 74 deletions(-) diff --git a/packages/tests/tests/enr.node.spec.ts b/packages/tests/tests/enr.node.spec.ts index 1f84370f32..725af4cdbc 100644 --- a/packages/tests/tests/enr.node.spec.ts +++ b/packages/tests/tests/enr.node.spec.ts @@ -31,8 +31,6 @@ describe("ENR Interop: nwaku", function () { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(multiAddrWithId); await waitForRemotePeer(waku, [Protocols.Relay]); @@ -65,8 +63,6 @@ describe("ENR Interop: nwaku", function () { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(multiAddrWithId); await waitForRemotePeer(waku, [Protocols.Relay]); @@ -99,8 +95,6 @@ describe("ENR Interop: nwaku", function () { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(multiAddrWithId); await waitForRemotePeer(waku, [Protocols.Relay]); diff --git a/packages/tests/tests/filter.node.spec.ts b/packages/tests/tests/filter.node.spec.ts index 01e29b6ce6..f9a62f9663 100644 --- a/packages/tests/tests/filter.node.spec.ts +++ b/packages/tests/tests/filter.node.spec.ts @@ -34,8 +34,6 @@ describe("Waku Filter", () => { libp2p: { addresses: { listen: ["/ip4/0.0.0.0/tcp/0/ws"] } }, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Filter, Protocols.LightPush]); }); diff --git a/packages/tests/tests/light_push.node.spec.ts b/packages/tests/tests/light_push.node.spec.ts index ed098ca9f6..3fbb0d6807 100644 --- a/packages/tests/tests/light_push.node.spec.ts +++ b/packages/tests/tests/light_push.node.spec.ts @@ -39,8 +39,6 @@ describe("Waku Light Push [node only]", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.LightPush]); @@ -75,8 +73,6 @@ describe("Waku Light Push [node only]", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.LightPush]); diff --git a/packages/tests/tests/relay.node.spec.ts b/packages/tests/tests/relay.node.spec.ts index babd43d204..578aaaa57d 100644 --- a/packages/tests/tests/relay.node.spec.ts +++ b/packages/tests/tests/relay.node.spec.ts @@ -66,9 +66,6 @@ describe("Waku Relay [node only]", () => { log("Instances started, adding waku2 to waku1's address book"); waku1.addPeerToAddressBook( waku2.libp2p.peerId, - // TODO: Upgrade libp2p package. - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore: New multiaddr type but they seem mostly compatible waku2.libp2p.getMultiaddrs() ); @@ -286,16 +283,10 @@ describe("Waku Relay [node only]", () => { waku1.addPeerToAddressBook( waku2.libp2p.peerId, - // TODO: Upgrade libp2p package. - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore: New multiaddr type but they seem mostly compatible waku2.libp2p.getMultiaddrs() ); waku3.addPeerToAddressBook( waku2.libp2p.peerId, - // TODO: Upgrade libp2p package. - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore: New multiaddr type but they seem mostly compatible waku2.libp2p.getMultiaddrs() ); @@ -346,8 +337,6 @@ describe("Waku Relay [node only]", () => { nwaku = new Nwaku(this.test?.ctx?.currentTest?.title + ""); await nwaku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Relay]); }); @@ -445,11 +434,7 @@ describe("Waku Relay [node only]", () => { const nwakuMultiaddr = await nwaku.getMultiaddrWithId(); await Promise.all([ - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos waku1.dial(nwakuMultiaddr), - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos waku2.dial(nwakuMultiaddr), ]); diff --git a/packages/tests/tests/store.node.spec.ts b/packages/tests/tests/store.node.spec.ts index 38b076bb67..da6deeece3 100644 --- a/packages/tests/tests/store.node.spec.ts +++ b/packages/tests/tests/store.node.spec.ts @@ -59,8 +59,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -92,8 +90,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -134,8 +130,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -177,8 +171,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -218,8 +210,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -263,8 +253,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -347,11 +335,7 @@ describe("Waku Store", () => { log("Waku nodes created"); await Promise.all([ - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos waku1.dial(nimWakuMultiaddr), - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos waku2.dial(nimWakuMultiaddr), ]); @@ -433,8 +417,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -496,8 +478,6 @@ describe("Waku Store", () => { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); @@ -557,8 +537,6 @@ describe("Waku Store, custom pubsub topic", () => { pubSubTopic: customPubSubTopic, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(await nwaku.getMultiaddrWithId()); await waitForRemotePeer(waku, [Protocols.Store]); diff --git a/packages/tests/tests/wait_for_remote_peer.node.spec.ts b/packages/tests/tests/wait_for_remote_peer.node.spec.ts index 9ba26feeb3..96aeba1ed3 100644 --- a/packages/tests/tests/wait_for_remote_peer.node.spec.ts +++ b/packages/tests/tests/wait_for_remote_peer.node.spec.ts @@ -36,8 +36,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku1.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku1.dial(multiAddrWithId); await delay(1000); await waitForRemotePeer(waku1, [Protocols.Relay]); @@ -66,8 +64,6 @@ describe("Wait for remote peer", function () { const waitPromise = waitForRemotePeer(waku1, [Protocols.Relay]); await delay(1000); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku1.dial(multiAddrWithId); await waitPromise; @@ -113,8 +109,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku2.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku2.dial(multiAddrWithId); await delay(1000); await waitForRemotePeer(waku2, [Protocols.Store]); @@ -144,8 +138,6 @@ describe("Wait for remote peer", function () { await waku2.start(); const waitPromise = waitForRemotePeer(waku2, [Protocols.Store], 2000); await delay(1000); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku2.dial(multiAddrWithId); await waitPromise; @@ -172,8 +164,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku2.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku2.dial(multiAddrWithId); await waitForRemotePeer(waku2, [Protocols.LightPush]); @@ -202,8 +192,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku2.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku2.dial(multiAddrWithId); await waitForRemotePeer(waku2, [Protocols.Filter]); @@ -233,8 +221,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku2.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku2.dial(multiAddrWithId); await waitForRemotePeer(waku2); @@ -271,8 +257,6 @@ describe("Wait for remote peer", function () { staticNoiseKey: NOISE_KEY_1, }); await waku1.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku1.dial(multiAddrWithId); await waitForRemotePeer(waku1); diff --git a/packages/tests/tests/waku.node.spec.ts b/packages/tests/tests/waku.node.spec.ts index 3fb2ea024e..587f6ab808 100644 --- a/packages/tests/tests/waku.node.spec.ts +++ b/packages/tests/tests/waku.node.spec.ts @@ -46,8 +46,6 @@ describe("Waku Dial [node only]", function () { staticNoiseKey: NOISE_KEY_1, }); await waku.start(); - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos await waku.dial(multiAddrWithId); await waitForRemotePeer(waku); @@ -74,8 +72,6 @@ describe("Waku Dial [node only]", function () { waku = await createLightNode({ staticNoiseKey: NOISE_KEY_1, libp2p: { - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos peerDiscovery: [new PeerDiscoveryStaticPeers([multiAddrWithId])], }, }); @@ -103,8 +99,6 @@ describe("Waku Dial [node only]", function () { staticNoiseKey: NOISE_KEY_1, libp2p: { peerDiscovery: [ - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore TODO: uniformize usage of multiaddr lib across repos new PeerDiscoveryStaticPeers([await nwaku.getMultiaddrWithId()]), ], }, @@ -149,9 +143,6 @@ describe("Decryption Keys", () => { waku1.addPeerToAddressBook( waku2.libp2p.peerId, - // TODO: Upgrade libp2p package. - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore: New multiaddr type but they seem mostly compatible waku2.libp2p.getMultiaddrs() );