Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: run tests on webkit for webRTC #1832

Closed
wants to merge 10 commits into from
Closed
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 12 additions & 11 deletions packages/transport-webrtc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,20 @@
"test": "aegir test -t browser",
"test:chrome": "aegir test -t browser --cov",
"test:firefox": "aegir test -t browser -- --browser firefox",
"test:webkit": "aegir test -t browser -- --browser webkit",
"lint": "aegir lint",
"lint:fix": "aegir lint --fix",
"clean": "aegir clean",
"dep-check": "aegir dep-check"
"dep-check": "aegir dep-check -i protons"
maschad marked this conversation as resolved.
Show resolved Hide resolved
},
"dependencies": {
"@chainsafe/libp2p-noise": "^12.0.1",
"@libp2p/interface": "~0.0.1",
"@libp2p/interface-internal": "~0.0.1",
"@libp2p/logger": "^2.0.0",
"@libp2p/peer-id": "^2.0.0",
"@multiformats/mafmt": "^12.1.2",
"@libp2p/interface": "^0.0.1",
"@libp2p/interface-compliance-tests": "^3.0.7",
"@libp2p/interface-internal": "^0.0.1",
"@libp2p/logger": "^2.1.1",
"@libp2p/peer-id": "^2.0.4",
"@multiformats/mafmt": "^12.1.5",
"@multiformats/multiaddr": "^12.1.3",
"abortable-iterator": "^5.0.1",
"detect-browser": "^5.3.0",
Expand All @@ -68,17 +70,16 @@
"uint8arrays": "^4.0.4"
},
"devDependencies": {
"@chainsafe/libp2p-yamux": "^4.0.1",
"@libp2p/interface-compliance-tests": "^3.0.0",
"@libp2p/peer-id-factory": "^2.0.0",
"@libp2p/websockets": "^6.0.0",
"@chainsafe/libp2p-yamux": "^4.0.2",
"@libp2p/peer-id-factory": "^2.0.4",
"@libp2p/websockets": "^6.0.3",
maschad marked this conversation as resolved.
Show resolved Hide resolved
"@types/sinon": "^10.0.15",
"aegir": "^39.0.10",
"delay": "^6.0.0",
"it-length": "^3.0.2",
"it-map": "^3.0.3",
"it-pair": "^2.0.6",
"libp2p": "^0.45.0",
"libp2p": "^0.45.9",
maschad marked this conversation as resolved.
Show resolved Hide resolved
"protons": "^7.0.2",
"sinon": "^15.1.2",
"sinon-ts": "^1.0.0"
Expand Down
19 changes: 10 additions & 9 deletions packages/transport-webrtc/test/basics.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -85,15 +85,16 @@ describe('basics', () => {
remoteNode = await createNode()
})

afterEach(async () => {
if (localNode != null) {
await localNode.stop()
}

if (remoteNode != null) {
await remoteNode.stop()
}
})
// TODO: Streams are not closing gracefully, re-introduce after https://github.com/libp2p/js-libp2p/issues/1793 is addressed
maschad marked this conversation as resolved.
Show resolved Hide resolved
// afterEach(async () => {
// if (localNode != null) {
// await localNode.stop()
// }

// if (remoteNode != null) {
// await remoteNode.stop()
// }
// })

it('can dial through a relay', async () => {
const connection = await connectNodes()
Expand Down