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

Commit d3dc3d3

Browse files
authored
test: another add recursive test (#743)
* test: another add recursive test * chore: update deps
1 parent 02efd7c commit d3dc3d3

File tree

2 files changed

+25
-3
lines changed

2 files changed

+25
-3
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@
103103
"ipfs-multipart": "^0.1.0",
104104
"ipfs-repo": "^0.11.2",
105105
"ipfs-unixfs": "^0.1.9",
106-
"ipfs-unixfs-engine": "^0.15.2",
106+
"ipfs-unixfs-engine": "^0.15.4",
107107
"ipld-resolver": "^0.4.3",
108108
"isstream": "^0.1.2",
109109
"libp2p-floodsub": "0.7.2",
@@ -171,4 +171,4 @@
171171
"nginnever <[email protected]>",
172172
"npmcdn-to-unpkg-bot <[email protected]>"
173173
]
174-
}
174+
}

test/cli/test-files.js

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ describe('files', () => {
7272
})
7373
})
7474

75-
it('add recursively', () => {
75+
it('add recursively test 1', () => {
7676
return ipfs('files add -r src/init-files/init-docs').then((out) => {
7777
expect(out).to.be.eql([
7878
'added QmYE7xo6NxbHEVEHej1yzxijYaNY51BaeKxjXxn6Ssa6Bs init-docs/tour/0.0-intro',
@@ -89,5 +89,27 @@ describe('files', () => {
8989
].join('\n'))
9090
})
9191
})
92+
93+
it('add recursively test 2', () => {
94+
return ipfs('files add -r test').then((out) => {
95+
const nLines = out.split('\n').length
96+
expect(nLines).to.be.above(10)
97+
/*
98+
expect(out).to.be.eql([
99+
'added QmYE7xo6NxbHEVEHej1yzxijYaNY51BaeKxjXxn6Ssa6Bs init-docs/tour/0.0-intro',
100+
'added QmciSU8hfpAXKjvK5YLUSwApomGSWN5gFbP4EpDAEzu2Te init-docs/tour',
101+
'added QmTumTjvcYCAvRRwQ8sDRxh8ezmrcr88YFU7iYNroGGTBZ init-docs/security-notes',
102+
'added QmPZ9gcCEpqKTo6aq61g2nXGUhM4iCL3ewB6LDXZCtioEB init-docs/readme',
103+
'added QmdncfsVm2h5Kqq9hPmU7oAVX2zTSVP3L869tgTbPYnsha init-docs/quick-start',
104+
'added QmY5heUM5qgRubMDD1og9fhCPA6QdkMp3QCwd4s7gJsyE7 init-docs/help',
105+
'added QmQN88TEidd3RY2u3dpib49fERTDfKtDpvxnvczATNsfKT init-docs/docs/index',
106+
'added QmegvLXxpVKiZ4b57Xs1syfBVRd8CbucVHAp7KpLQdGieC init-docs/docs',
107+
'added QmYCvbfNbCwFR45HiNP45rwJgvatpiW38D961L5qAhUM5Y init-docs/contact',
108+
'added QmZTR5bcpQD7cFgTorqxZDYaew1Wqgfbd2ud9QqGPAkK2V init-docs/about',
109+
'added QmUhUuiTKkkK8J6JZ9zmj8iNHPuNfGYcszgRumzhHBxEEU init-docs'
110+
].join('\n'))
111+
*/
112+
})
113+
})
92114
})
93115
})

0 commit comments

Comments
 (0)