diff --git a/package.json b/package.json index 5fd0ed098..0b435c537 100644 --- a/package.json +++ b/package.json @@ -12,17 +12,17 @@ "ipfs": false }, "scripts": { - "test": "aegir test", + "test": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir test", "test:node": "aegir test -t node", - "test:browser": "node --max-old-space-size=8192 $(npm bin)/aegir test -t browser", - "test:webworker": "node --max-old-space-size=8192 $(npm bin)/aegir test -t webworker", + "test:browser": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir test -t browser", + "test:webworker": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir test -t webworker", "lint": "aegir lint", "build": "aegir build", - "release": "node --max-old-space-size=8192 $(npm bin)/aegir release ", - "release-minor": "node --max-old-space-size=8192 $(npm bin)/aegir release --type minor ", - "release-major": "node --max-old-space-size=8192 $(npm bin)/aegir release --type major ", - "coverage": "node --max-old-space-size=8192 $(npm bin)/aegir coverage --timeout 100000", - "coverage-publish": "node --max-old-space-size=8192 $(npm bin)/aegir coverage --provider coveralls --timeout 100000" + "release": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir release ", + "release-minor": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir release --type minor ", + "release-major": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir release --type major ", + "coverage": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir coverage --timeout 100000", + "coverage-publish": "cross-env NODE_OPTIONS='--max-old-space-size=8192' aegir coverage --provider coveralls --timeout 100000" }, "dependencies": { "async": "^2.6.0", @@ -67,13 +67,15 @@ "devDependencies": { "aegir": "^13.0.0", "chai": "^4.1.2", + "cross-env": "^5.1.3", "dirty-chai": "^2.0.1", "eslint-plugin-react": "^7.6.1", "go-ipfs-dep": "^0.4.13", "gulp": "^3.9.1", - "interface-ipfs-core": "~0.51.0", "hapi": "^17.2.0", - "ipfsd-ctl": "~0.28.0", + "interface-ipfs-core": "~0.51.0", + "ipfs": "~0.28.0", + "ipfsd-ctl": "~0.29.0", "pre-commit": "^1.2.2", "socket.io": "^2.0.4", "socket.io-client": "^2.0.4", diff --git a/test/bitswap.spec.js b/test/bitswap.spec.js index 8bd16f2c0..2a69a1b06 100644 --- a/test/bitswap.spec.js +++ b/test/bitswap.spec.js @@ -19,7 +19,7 @@ describe('.bitswap', function () { before(function (done) { this.timeout(20 * 1000) // slow CI - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/commands.spec.js b/test/commands.spec.js index cb69c0b8b..d8859c5b4 100644 --- a/test/commands.spec.js +++ b/test/commands.spec.js @@ -17,7 +17,7 @@ describe('.commands', function () { let ipfs before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/constructor.spec.js b/test/constructor.spec.js index 74042c176..82da19608 100644 --- a/test/constructor.spec.js +++ b/test/constructor.spec.js @@ -27,7 +27,7 @@ describe('ipfs-api constructor tests', () => { before(function (done) { this.timeout(20 * 1000) // slow CI - f.spawn((err, node) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, node) => { expect(err).to.not.exist() ipfsd = node apiAddr = node.apiAddr.toString() diff --git a/test/diag.spec.js b/test/diag.spec.js index ef2f7c605..216f0ac9a 100644 --- a/test/diag.spec.js +++ b/test/diag.spec.js @@ -20,7 +20,7 @@ describe('.diag', function () { let ipfs before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/files.spec.js b/test/files.spec.js index cf5eaaff1..41c5bc1a8 100644 --- a/test/files.spec.js +++ b/test/files.spec.js @@ -37,7 +37,7 @@ describe('.files (the MFS API part)', function () { const expectedMultihash = 'Qma4hjFTnCasJ8PVp3mZbZK5g2vGDT4LByLJ7m8ciyRFZP' before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/get.spec.js b/test/get.spec.js index e93df5182..4e5f6f743 100644 --- a/test/get.spec.js +++ b/test/get.spec.js @@ -31,7 +31,7 @@ describe('.get (specific go-ipfs features)', function () { before((done) => { series([ - (cb) => f.spawn((err, _ipfsd) => { + (cb) => f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/interface/block.spec.js b/test/interface/block.spec.js index b7b4181cf..180f17a04 100644 --- a/test/interface/block.spec.js +++ b/test/interface/block.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/bootstrap.spec.js b/test/interface/bootstrap.spec.js index 4e2e4bd00..caea5856e 100644 --- a/test/interface/bootstrap.spec.js +++ b/test/interface/bootstrap.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/config.spec.js b/test/interface/config.spec.js index 0c47b099b..aeb4a6a9a 100644 --- a/test/interface/config.spec.js +++ b/test/interface/config.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/dht.spec.js b/test/interface/dht.spec.js index 4e02d8343..2b324cb99 100644 --- a/test/interface/dht.spec.js +++ b/test/interface/dht.spec.js @@ -12,7 +12,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/files-mfs.spec.js b/test/interface/files-mfs.spec.js index 9923adc11..6de81af4e 100644 --- a/test/interface/files-mfs.spec.js +++ b/test/interface/files-mfs.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/files.spec.js b/test/interface/files.spec.js index 2b464be20..c99f768a6 100644 --- a/test/interface/files.spec.js +++ b/test/interface/files.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/key.spec.js b/test/interface/key.spec.js index b34221f70..56f6e6893 100644 --- a/test/interface/key.spec.js +++ b/test/interface/key.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/miscellaneous.spec.js b/test/interface/miscellaneous.spec.js index 1d203604e..c890a2fa3 100644 --- a/test/interface/miscellaneous.spec.js +++ b/test/interface/miscellaneous.spec.js @@ -12,7 +12,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/object.spec.js b/test/interface/object.spec.js index bdc74e227..e76c45673 100644 --- a/test/interface/object.spec.js +++ b/test/interface/object.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/pin.spec.js b/test/interface/pin.spec.js index dd7891461..e56bc413d 100644 --- a/test/interface/pin.spec.js +++ b/test/interface/pin.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/pubsub.spec.js b/test/interface/pubsub.spec.js index ddba34e2a..154fec2f4 100644 --- a/test/interface/pubsub.spec.js +++ b/test/interface/pubsub.spec.js @@ -16,7 +16,7 @@ if (isNode) { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn({ args: ['--enable-pubsub-experiment'] }, + f.spawn({ initOptions: { bits: 1024 }, args: ['--enable-pubsub-experiment'] }, (err, _ipfsd) => { if (err) { return cb(err) diff --git a/test/interface/repo.spec.js b/test/interface/repo.spec.js index 211f8bb41..c6966772d 100644 --- a/test/interface/repo.spec.js +++ b/test/interface/repo.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/stats.spec.js b/test/interface/stats.spec.js index 1a2a9aa15..eee30ad98 100644 --- a/test/interface/stats.spec.js +++ b/test/interface/stats.spec.js @@ -13,7 +13,7 @@ const common = { setup: function (callback) { callback(null, { spawnNode: (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/interface/swarm.spec.js b/test/interface/swarm.spec.js index 735f60d95..56b9cbe41 100644 --- a/test/interface/swarm.spec.js +++ b/test/interface/swarm.spec.js @@ -23,7 +23,7 @@ const common = { config = undefined } - f.spawn({ repoPath, config }, (err, _ipfsd) => { + f.spawn({ repoPath, config, initOptions: { bits: 1024 } }, (err, _ipfsd) => { if (err) { return cb(err) } diff --git a/test/key.spec.js b/test/key.spec.js index 5d958708f..24a2a77b1 100644 --- a/test/key.spec.js +++ b/test/key.spec.js @@ -17,7 +17,7 @@ describe('.key', function () { let ipfs before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/log.spec.js b/test/log.spec.js index 4c780e37d..b45911c2f 100644 --- a/test/log.spec.js +++ b/test/log.spec.js @@ -17,7 +17,7 @@ describe('.log', function () { let ipfs before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/name.spec.js b/test/name.spec.js index cb6c691f8..ca486f11b 100644 --- a/test/name.spec.js +++ b/test/name.spec.js @@ -27,7 +27,7 @@ describe('.name', () => { series([ (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) @@ -35,7 +35,7 @@ describe('.name', () => { }) }, (cb) => { - f.spawn((err, node) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, node) => { expect(err).to.not.exist() other = node.api otherd = node diff --git a/test/ping.spec.js b/test/ping.spec.js index c39673615..747464798 100644 --- a/test/ping.spec.js +++ b/test/ping.spec.js @@ -23,7 +23,7 @@ describe.skip('.ping', () => { series([ (cb) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) @@ -32,7 +32,7 @@ describe.skip('.ping', () => { }, (cb) => { console.log('going to spawn second node') - f.spawn((err, node) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, node) => { expect(err).to.not.exist() other = node.api otherd = node diff --git a/test/pubsub-in-browser.spec.js b/test/pubsub-in-browser.spec.js index 95070e459..ce2f1139e 100644 --- a/test/pubsub-in-browser.spec.js +++ b/test/pubsub-in-browser.spec.js @@ -47,7 +47,7 @@ describe('.pubsub is not supported in the browser, yet!', function () { let ipfsd before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/refs.spec.js b/test/refs.spec.js index d74717597..e8d36b541 100644 --- a/test/refs.spec.js +++ b/test/refs.spec.js @@ -35,7 +35,7 @@ describe('.refs', function () { } waterfall([ - (cb) => f.spawn(cb), + (cb) => f.spawn({ initOptions: { bits: 1024 } }, cb), (_ipfsd, cb) => { ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/repo.spec.js b/test/repo.spec.js index ee3f7f0b6..f08c50ca1 100644 --- a/test/repo.spec.js +++ b/test/repo.spec.js @@ -16,7 +16,7 @@ describe('.repo', function () { let ipfsd before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/stats.spec.js b/test/stats.spec.js index 73cd29774..81abb945a 100644 --- a/test/stats.spec.js +++ b/test/stats.spec.js @@ -16,7 +16,7 @@ describe('stats', function () { let ipfsd before((done) => { - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr) diff --git a/test/util.spec.js b/test/util.spec.js index 1573620fd..8f5362b09 100644 --- a/test/util.spec.js +++ b/test/util.spec.js @@ -22,7 +22,7 @@ describe('.util', () => { before(function (done) { this.timeout(20 * 1000) // slow CI - f.spawn((err, _ipfsd) => { + f.spawn({ initOptions: { bits: 1024 } }, (err, _ipfsd) => { expect(err).to.not.exist() ipfsd = _ipfsd ipfs = IPFSApi(_ipfsd.apiAddr)