diff --git a/packages/integration-tests/package.json b/packages/integration-tests/package.json index fab36b2e26..9d2622dc0f 100644 --- a/packages/integration-tests/package.json +++ b/packages/integration-tests/package.json @@ -29,18 +29,27 @@ "test:firefox": "aegir test -t browser -- --browser firefox", "test:firefox-webworker": "aegir test -t webworker -- --browser firefox", "test:node": "aegir test -t node --cov", + "test:interop": "aegir test -t node -f dist/test/interop.js", "dep-check": "aegir dep-check" }, "devDependencies": { + "@chainsafe/libp2p-gossipsub": "^10.0.0", "@chainsafe/libp2p-noise": "^14.0.0", "@chainsafe/libp2p-yamux": "^6.0.1", "@libp2p/circuit-relay-v2": "^1.0.0", + "@libp2p/crypto": "^3.0.1", + "@libp2p/daemon-client": "^8.0.0", + "@libp2p/daemon-server": "^7.0.0", "@libp2p/dcutr": "^1.0.0", "@libp2p/fetch": "^1.0.0", + "@libp2p/floodsub": "^8.0.16", "@libp2p/identify": "^1.0.0", "@libp2p/interface": "^1.0.0", "@libp2p/interface-compliance-tests": "^5.0.0", "@libp2p/interface-internal": "^0.1.9", + "@libp2p/interop": "^10.0.0", + "@libp2p/kad-dht": "^11.0.2", + "@libp2p/logger": "^4.0.1", "@libp2p/mplex": "^10.0.0", "@libp2p/peer-id": "^4.0.0", "@libp2p/peer-id-factory": "^3.0.8", @@ -53,6 +62,8 @@ "@multiformats/multiaddr": "^12.1.10", "aegir": "^41.0.2", "delay": "^6.0.0", + "execa": "^8.0.1", + "go-libp2p": "^1.1.1", "it-all": "^3.0.3", "it-pipe": "^3.0.1", "libp2p": "^1.0.0", diff --git a/packages/libp2p/test/interop.ts b/packages/integration-tests/test/interop.ts similarity index 99% rename from packages/libp2p/test/interop.ts rename to packages/integration-tests/test/interop.ts index 16e7b501f2..ce2802eee7 100644 --- a/packages/libp2p/test/interop.ts +++ b/packages/integration-tests/test/interop.ts @@ -18,8 +18,8 @@ import { tcp } from '@libp2p/tcp' import { multiaddr } from '@multiformats/multiaddr' import { execa } from 'execa' import { path as p2pd } from 'go-libp2p' +import { createLibp2p, type Libp2pOptions, type ServiceFactoryMap } from 'libp2p' import pDefer from 'p-defer' -import { createLibp2p, type Libp2pOptions, type ServiceFactoryMap } from '../src/index.js' import type { ServiceMap, PeerId } from '@libp2p/interface' import type { SpawnOptions, Daemon, DaemonFactory } from '@libp2p/interop' diff --git a/packages/libp2p/.aegir.js b/packages/libp2p/.aegir.js index 8372a3dfc2..009b168035 100644 --- a/packages/libp2p/.aegir.js +++ b/packages/libp2p/.aegir.js @@ -1,5 +1,3 @@ -import { pipe } from 'it-pipe' - /** @type {import('aegir').PartialOptions} */ export default { build: { @@ -18,7 +16,7 @@ export default { const { plaintext } = await import('@libp2p/plaintext') const { circuitRelayServer, circuitRelayTransport } = await import('@libp2p/circuit-relay-v2') const { identify } = await import('@libp2p/identify') - const { echo, ECHO_PROTOCOL } = await import('./dist/test/fixtures/echo-service.js') + const { echo } = await import('./dist/test/fixtures/echo-service.js') const peerId = await createEd25519PeerId() const libp2p = await createLibp2p({ diff --git a/packages/libp2p/package.json b/packages/libp2p/package.json index 21bbf672b6..557cc0a745 100644 --- a/packages/libp2p/package.json +++ b/packages/libp2p/package.json @@ -81,8 +81,7 @@ "test:chrome-webworker": "aegir test -t webworker -f \"./dist/test/**/*.spec.js\"", "test:firefox": "aegir test -t browser -f \"./dist/test/**/*.spec.js\" -- --browser firefox", "test:firefox-webworker": "aegir test -t webworker -f \"./dist/test/**/*.spec.js\" -- --browser firefox", - "test:webkit": "aegir test -t browser -f \"./dist/test/**/*.spec.js\" -- --browser webkit", - "test:interop": "aegir test -t node -f dist/test/interop.js" + "test:webkit": "aegir test -t browser -f \"./dist/test/**/*.spec.js\" -- --browser webkit" }, "dependencies": { "@libp2p/crypto": "^3.0.1", @@ -120,17 +119,12 @@ "uint8arrays": "^4.0.6" }, "devDependencies": { - "@chainsafe/libp2p-gossipsub": "^10.0.0", "@chainsafe/libp2p-noise": "^14.0.0", "@chainsafe/libp2p-yamux": "^6.0.1", "@libp2p/bootstrap": "^10.0.2", "@libp2p/circuit-relay-v2": "^1.0.2", - "@libp2p/daemon-client": "^8.0.0", - "@libp2p/daemon-server": "^7.0.0", - "@libp2p/floodsub": "^8.0.16", "@libp2p/identify": "^1.0.1", "@libp2p/interface-compliance-tests": "^5.0.2", - "@libp2p/interop": "^10.0.0", "@libp2p/kad-dht": "^11.0.2", "@libp2p/mdns": "^10.0.2", "@libp2p/mplex": "^10.0.2", @@ -138,8 +132,6 @@ "@libp2p/tcp": "^9.0.2", "@libp2p/websockets": "^8.0.2", "aegir": "^41.0.2", - "execa": "^8.0.1", - "go-libp2p": "^1.1.1", "it-pushable": "^3.2.1", "p-event": "^6.0.0", "p-times": "^4.0.0",