Skip to content
This repository was archived by the owner on Mar 10, 2020. It is now read-only.

refactor: moved bootstrap tests to interface-ipfs-core #692

Merged
merged 2 commits into from
Feb 15, 2018
Merged
Show file tree
Hide file tree
Changes from all 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
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ipfs-api",
"version": "18.0.0",
"description": "A client library for the IPFS HTTP API. Follows interface-ipfs-core spec",
"description": "A client library for the IPFS HTTP API",
"main": "src/index.js",
"browser": {
"glob": false,
Expand Down Expand Up @@ -71,7 +71,7 @@
"eslint-plugin-react": "^7.6.1",
"go-ipfs-dep": "^0.4.13",
"gulp": "^3.9.1",
"interface-ipfs-core": "~0.50.1",
"interface-ipfs-core": "~0.51.0",
"hapi": "^17.2.0",
"ipfsd-ctl": "~0.28.0",
"pre-commit": "^1.2.2",
Expand Down
113 changes: 0 additions & 113 deletions test/bootstrap.spec.js

This file was deleted.

32 changes: 32 additions & 0 deletions test/interface/bootstrap.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/* eslint-env mocha */

'use strict'

const test = require('interface-ipfs-core')
const parallel = require('async/parallel')

const IPFSApi = require('../../src')
const f = require('../utils/factory')

const nodes = []
const common = {
setup: function (callback) {
callback(null, {
spawnNode: (cb) => {
f.spawn((err, _ipfsd) => {
if (err) {
return cb(err)
}

nodes.push(_ipfsd)
cb(null, IPFSApi(_ipfsd.apiAddr))
})
}
})
},
teardown: function (callback) {
parallel(nodes.map((node) => (cb) => node.stop(cb)), callback)
}
}

test.bootstrap(common)