Skip to content
This repository was archived by the owner on Feb 12, 2024. It is now read-only.

Commit 9e61377

Browse files
authored
test: port interop tests to interop repo (#1157)
* port interop tests to interop repo * fix
1 parent 1914da5 commit 9e61377

14 files changed

+23
-1207
lines changed

.aegir.js

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
const parallel = require('async/parallel')
44
const ads = require('./test/utils/another-daemon-spawner')
55
const js = ads.spawnJsNode
6-
const go = ads.spawnGoNode
76
const stop = ads.stopNodes
87

98
/*
@@ -20,13 +19,6 @@ function start (done) {
2019
(cb) => js([`${base}/10014`, `${base}/20014/ws`], true, 31014, 32014, cb),
2120
(cb) => js([`${base}/10015`, `${base}/20015/ws`], true, 31015, 32015, cb)
2221
], done)
23-
} else if (process.env.IPFS_TEST === 'interop') {
24-
parallel([
25-
(cb) => go([`${base}/10027`, `${base}/20027/ws`], true, 33027, 44027, cb),
26-
(cb) => go([`${base}/10028`, `${base}/20028/ws`], true, 33028, 44028, cb),
27-
(cb) => go([`${base}/10031`, `${base}/20031/ws`], true, 33031, 44031, cb),
28-
(cb) => go([`${base}/10032`, `${base}/20032/ws`], true, 33032, 44032, cb)
29-
], done)
3022
} else if (process.env.IPFS_TEST === 'bootstrapers') {
3123
done()
3224
}

README.md

Lines changed: 11 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@
2828
<a href=""><img src="https://img.shields.io/badge/npm-%3E%3D3.0.0-orange.svg?style=flat-square" /></a>
2929
<a href=""><img src="https://img.shields.io/badge/Node.js-%3E%3D6.0.0-orange.svg?style=flat-square" /></a>
3030
<br>
31-
<!-- Hidding this until we have SauceLabs situation figured out, right now it is just misleading
32-
<a href="https://saucelabs.com/u/js-ipfs"><img src="https://saucelabs.com/browser-matrix/js-ipfs.svg" /></a> -->
3331
</p>
3432

3533
### Project status
@@ -494,51 +492,42 @@ A way to mitigate this in Chrome, is to run your IPFS node inside a Service Work
494492
> npm test
495493

496494
# run just IPFS tests in Node.js
497-
> npm run test:unit:node:core
495+
> npm run test:node:core
498496

499497
# run just IPFS core tests
500-
> npm run test:unit:node:core
498+
> npm run test:node:core
501499

502500
# run just IPFS HTTP-API tests
503-
> npm run test:unit:node:http
501+
> npm run test:node:http
504502

505503
# run just IPFS CLI tests
506-
> npm run test:unit:node:cli
504+
> npm run test:node:cli
507505

508506
# run just IPFS core tests in the Browser (Chrome)
509-
> npm run test:unit:browser
507+
> npm run test:browser
510508
```
511509

512510
### Run interop tests
513511

514-
```sh
515-
# run all the interop tsts
516-
> npm run test:interop
517-
518-
# run just IPFS interop tests in Node.js using one go-ipfs daemon and one js-ipfs daemon
519-
> npm run test:interop:node
520-
521-
# run just IPFS interop testsin the Browser (Chrome) using one instance in the browser and one go-ipfs daemon
522-
> npm run test:interop:browser
523-
```
512+
Run the interop tests with https://github.com/ipfs/interop
524513

525514
### Run benchmark tests
526515

527516
```sh
528517
# run all the benchmark tests
529-
> npm run test:benchmark
518+
> npm run benchmark
530519

531520
# run just IPFS benchmarks in Node.js
532-
> npm run test:benchmark:node
521+
> npm run benchmark:node
533522

534523
# run just IPFS benchmarks in Node.js for an IPFS instance
535-
> npm run test:benchmark:node:core
524+
> npm run benchmark:node:core
536525

537526
# run just IPFS benchmarks in Node.js for an IPFS daemon
538-
> npm run test:benchmark:node:http
527+
> npm run benchmark:node:http
539528

540529
# run just IPFS benchmarks in the browser (Chrome)
541-
> npm run test:benchmark:browser
530+
> npm run benchmark:browser
542531
```
543532

544533
### Lint

package.json

Lines changed: 12 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -24,24 +24,21 @@
2424
"test": "aegir test -t node -t browser --no-cors",
2525
"test:node": "aegir test -t node",
2626
"test:browser": "aegir test -t browser -t webworker --no-cors",
27+
"test:node": "aegir test -t node",
28+
"test:node:core": "aegir test -t node -f test/core/**.js",
29+
"test:node:http": "aegir test -t node -f test/http-api/index.js",
30+
"test:node:gateway": "aegir test -t node -f test/gateway/index.js",
31+
"test:node:cli": "aegir test -t node -f test/cli/index.js",
32+
"test:browser": "aegir test -t browser --no-cors",
33+
"test:bootstrapers": "IPFS_TEST=bootstrapers aegir test -t browser -f test/bootstrapers.js",
34+
"benchmark": "echo \"Error: no benchmarks yet\" && exit 1",
35+
"benchmark:node": "echo \"Error: no benchmarks yet\" && exit 1",
36+
"benchmark:node:core": "echo \"Error: no benchmarks yet\" && exit 1",
37+
"benchmark:node:http": "echo \"Error: no benchmarks yet\" && exit 1",
38+
"benchmark:browser": "echo \"Error: no benchmarks yet\" && exit 1",
2739
"release": "aegir release -t node -t browser",
2840
"release-minor": "aegir release --type minor -t node -t browser",
2941
"release-major": "aegir release --type major -t node -t browser",
30-
"test:unit:node": "aegir test -t node",
31-
"test:unit:node:core": "aegir test -t node -f test/core/**.js",
32-
"test:unit:node:http": "aegir test -t node -f test/http-api/index.js",
33-
"test:unit:node:gateway": "aegir test -t node -f test/gateway/index.js",
34-
"test:unit:node:cli": "aegir test -t node -f test/cli/index.js",
35-
"test:unit:browser": "aegir test -t browser --no-cors",
36-
"test:interop": "IPFS_TEST=interop aegir test -t node -f test/interop",
37-
"test:interop:node": "IPFS_TEST=interop aegir test -t node -f test/interop/node.js",
38-
"test:interop:browser": "IPFS_TEST=interop aegir test -t browser -f test/interop/browser.js",
39-
"test:bootstrapers": "IPFS_TEST=bootstrapers aegir test -t browser -f test/bootstrapers.js",
40-
"test:benchmark": "echo \"Error: no benchmarks yet\" && exit 1",
41-
"test:benchmark:node": "echo \"Error: no benchmarks yet\" && exit 1",
42-
"test:benchmark:node:core": "echo \"Error: no benchmarks yet\" && exit 1",
43-
"test:benchmark:node:http": "echo \"Error: no benchmarks yet\" && exit 1",
44-
"test:benchmark:browser": "echo \"Error: no benchmarks yet\" && exit 1",
4542
"coverage": "aegir coverage",
4643
"coverage-publish": "aegir-coverage publish"
4744
},
@@ -76,7 +73,6 @@
7673
"form-data": "^2.3.1",
7774
"hat": "0.0.3",
7875
"interface-ipfs-core": "~0.36.15",
79-
"ipfsd-ctl": "~0.26.0",
8076
"left-pad": "^1.2.0",
8177
"lodash": "^4.17.4",
8278
"mocha": "^4.0.1",

test/interop/browser.js

Lines changed: 0 additions & 10 deletions
This file was deleted.

test/interop/circuit-relay.js

Lines changed: 0 additions & 167 deletions
This file was deleted.

0 commit comments

Comments
 (0)