From de8e25f1623599f5bdd2bb9fd9243b09bf497957 Mon Sep 17 00:00:00 2001 From: Matt Ober Date: Thu, 18 Jul 2019 13:23:19 -0500 Subject: [PATCH 1/4] Added opts to object stat command The ipfs object stat command couldn't handle the {timeout: '1s'} option (or any other options). We're already checking for the opts parameter so it makes sense that we should be sending it as well. Things work as desired now with this one line addition. --- src/object/stat.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/object/stat.js b/src/object/stat.js index 280e9f8e1..6488a297e 100644 --- a/src/object/stat.js +++ b/src/object/stat.js @@ -21,7 +21,8 @@ module.exports = (send) => { send({ path: 'object/stat', - args: cid.toString() + args: cid.toString(), + qs: opts }, callback) }) } From a749e03d857221447b2df9730ac434bd102e1a06 Mon Sep 17 00:00:00 2001 From: Alan Shaw Date: Fri, 26 Jul 2019 16:22:23 +0100 Subject: [PATCH 2/4] chore: fix test for files.ls --long License: MIT Signed-off-by: Alan Shaw --- package.json | 2 +- test/interface.spec.js | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 673b5e58d..cbdb3aece 100644 --- a/package.json +++ b/package.json @@ -86,7 +86,7 @@ "cross-env": "^5.2.0", "dirty-chai": "^2.0.1", "go-ipfs-dep": "~0.4.21", - "interface-ipfs-core": "^0.107.1", + "interface-ipfs-core": "github:ipfs/interface-js-ipfs-core#fix/resolve-ipns-test", "ipfsd-ctl": "~0.43.0", "nock": "^10.0.2", "stream-equal": "^1.1.1" diff --git a/test/interface.spec.js b/test/interface.spec.js index 1c7ed2b7d..4dcbcf114 100644 --- a/test/interface.spec.js +++ b/test/interface.spec.js @@ -182,7 +182,14 @@ describe('interface-ipfs-core tests', () => { ] }) - tests.filesMFS(defaultCommonFactory) + tests.filesMFS(defaultCommonFactory, { + skip: [ + { + name: 'should ls directory with long option', + reason: 'TODO unskip when go-ipfs supports --long https://github.com/ipfs/go-ipfs/pull/6528' + } + ] + }) tests.key(defaultCommonFactory, { skip: [ From 44fa13fa3ff386e6b5d47076b7eb9623a8307825 Mon Sep 17 00:00:00 2001 From: Alan Shaw Date: Fri, 26 Jul 2019 16:30:32 +0100 Subject: [PATCH 3/4] chore: skip missing endpoint tests License: MIT Signed-off-by: Alan Shaw --- test/interface.spec.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/interface.spec.js b/test/interface.spec.js index 4dcbcf114..962a076b4 100644 --- a/test/interface.spec.js +++ b/test/interface.spec.js @@ -49,6 +49,11 @@ describe('interface-ipfs-core tests', () => { { name: 'replace', reason: 'FIXME Waiting for fix on go-ipfs https://github.com/ipfs/js-ipfs-http-client/pull/307#discussion_r69281789 and https://github.com/ipfs/go-ipfs/issues/2927' + }, + // config.profile + { + name: 'profile', + reason: 'TODO not yet implemented https://github.com/ipfs/js-ipfs-http-client/pull/1030' } ] }) From 2fffc840390f15c532f4c4e7865541073bbbf624 Mon Sep 17 00:00:00 2001 From: Alan Shaw Date: Fri, 26 Jul 2019 16:39:09 +0100 Subject: [PATCH 4/4] chore: update interface-ipfs-core dep License: MIT Signed-off-by: Alan Shaw --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index cbdb3aece..5668a65ed 100644 --- a/package.json +++ b/package.json @@ -86,7 +86,7 @@ "cross-env": "^5.2.0", "dirty-chai": "^2.0.1", "go-ipfs-dep": "~0.4.21", - "interface-ipfs-core": "github:ipfs/interface-js-ipfs-core#fix/resolve-ipns-test", + "interface-ipfs-core": "^0.109.0", "ipfsd-ctl": "~0.43.0", "nock": "^10.0.2", "stream-equal": "^1.1.1"