@@ -37,10 +37,10 @@ module.exports = (common) => {
37
37
after ( ( done ) => common . teardown ( done ) )
38
38
39
39
describe ( '.mkdir' , function ( ) {
40
- it ( 'make directory on root' , ( done ) => {
40
+ it ( 'make directory on root' , function ( done ) {
41
41
if ( ! withGo ) {
42
42
console . log ( 'Not supported in js-ipfs yet' )
43
- return done ( )
43
+ this . skip ( )
44
44
}
45
45
46
46
ipfs . files . mkdir ( '/test' , ( err ) => {
@@ -49,10 +49,10 @@ module.exports = (common) => {
49
49
} )
50
50
} )
51
51
52
- it ( 'make directory and its parents' , ( done ) => {
52
+ it ( 'make directory and its parents' , function ( done ) {
53
53
if ( ! withGo ) {
54
54
console . log ( 'Not supported in js-ipfs yet' )
55
- return done ( )
55
+ this . skip ( )
56
56
}
57
57
58
58
ipfs . files . mkdir ( '/test/lv1/lv2' , { p : true } , ( err ) => {
@@ -61,10 +61,10 @@ module.exports = (common) => {
61
61
} )
62
62
} )
63
63
64
- it ( 'make already existent directory' , ( done ) => {
64
+ it ( 'make already existent directory' , function ( done ) {
65
65
if ( ! withGo ) {
66
66
console . log ( 'Not supported in js-ipfs yet' )
67
- return done ( )
67
+ this . skip ( )
68
68
}
69
69
70
70
ipfs . files . mkdir ( '/' , ( err ) => {
@@ -75,10 +75,10 @@ module.exports = (common) => {
75
75
} )
76
76
77
77
describe ( '.write' , function ( ) {
78
- it ( 'expect error' , ( done ) => {
78
+ it ( 'expect error' , function ( done ) {
79
79
if ( ! withGo ) {
80
80
console . log ( 'Not supported in js-ipfs yet' )
81
- return done ( )
81
+ this . skip ( )
82
82
}
83
83
84
84
ipfs . files . write ( '/test/a' , Buffer . from ( 'Hello, world!' ) , ( err ) => {
@@ -87,10 +87,10 @@ module.exports = (common) => {
87
87
} )
88
88
} )
89
89
90
- it ( 'expect no error' , ( done ) => {
90
+ it ( 'expect no error' , function ( done ) {
91
91
if ( ! withGo ) {
92
92
console . log ( 'Not supported in js-ipfs yet' )
93
- return done ( )
93
+ this . skip ( )
94
94
}
95
95
96
96
ipfs . files . write ( '/test/a' , Buffer . from ( 'Hello, world!' ) , { create : true } , ( err ) => {
@@ -101,10 +101,10 @@ module.exports = (common) => {
101
101
} )
102
102
103
103
describe ( '.cp' , function ( ) {
104
- it ( 'copy file, expect error' , ( done ) => {
104
+ it ( 'copy file, expect error' , function ( done ) {
105
105
if ( ! withGo ) {
106
106
console . log ( 'Not supported in js-ipfs yet' )
107
- return done ( )
107
+ this . skip ( )
108
108
}
109
109
110
110
ipfs . files . cp ( [ '/test/c' , '/test/b' ] , ( err ) => {
@@ -113,10 +113,10 @@ module.exports = (common) => {
113
113
} )
114
114
} )
115
115
116
- it ( 'copy file, expect no error' , ( done ) => {
116
+ it ( 'copy file, expect no error' , function ( done ) {
117
117
if ( ! withGo ) {
118
118
console . log ( 'Not supported in js-ipfs yet' )
119
- return done ( )
119
+ this . skip ( )
120
120
}
121
121
122
122
ipfs . files . cp ( [ '/test/a' , '/test/b' ] , ( err ) => {
@@ -125,10 +125,10 @@ module.exports = (common) => {
125
125
} )
126
126
} )
127
127
128
- it ( 'copy dir, expect error' , ( done ) => {
128
+ it ( 'copy dir, expect error' , function ( done ) {
129
129
if ( ! withGo ) {
130
130
console . log ( 'Not supported in js-ipfs yet' )
131
- return done ( )
131
+ this . skip ( )
132
132
}
133
133
134
134
ipfs . files . cp ( [ '/test/lv1/lv3' , '/test/lv1/lv4' ] , ( err ) => {
@@ -137,10 +137,10 @@ module.exports = (common) => {
137
137
} )
138
138
} )
139
139
140
- it ( 'copy dir, expect no error' , ( done ) => {
140
+ it ( 'copy dir, expect no error' , function ( done ) {
141
141
if ( ! withGo ) {
142
142
console . log ( 'Not supported in js-ipfs yet' )
143
- return done ( )
143
+ this . skip ( )
144
144
}
145
145
146
146
ipfs . files . cp ( [ '/test/lv1/lv2' , '/test/lv1/lv3' ] , ( err ) => {
@@ -151,10 +151,10 @@ module.exports = (common) => {
151
151
} )
152
152
153
153
describe ( '.mv' , function ( ) {
154
- it ( 'move file, expect error' , ( done ) => {
154
+ it ( 'move file, expect error' , function ( done ) {
155
155
if ( ! withGo ) {
156
156
console . log ( 'Not supported in js-ipfs yet' )
157
- return done ( )
157
+ this . skip ( )
158
158
}
159
159
160
160
ipfs . files . mv ( [ '/test/404' , '/test/a' ] , ( err ) => {
@@ -163,10 +163,10 @@ module.exports = (common) => {
163
163
} )
164
164
} )
165
165
166
- it ( 'move file, expect no error' , ( done ) => {
166
+ it ( 'move file, expect no error' , function ( done ) {
167
167
if ( ! withGo ) {
168
168
console . log ( 'Not supported in js-ipfs yet' )
169
- return done ( )
169
+ this . skip ( )
170
170
}
171
171
172
172
ipfs . files . mv ( [ '/test/a' , '/test/c' ] , ( err ) => {
@@ -175,10 +175,10 @@ module.exports = (common) => {
175
175
} )
176
176
} )
177
177
178
- it ( 'move dir, expect error' , ( done ) => {
178
+ it ( 'move dir, expect error' , function ( done ) {
179
179
if ( ! withGo ) {
180
180
console . log ( 'Not supported in js-ipfs yet' )
181
- return done ( )
181
+ this . skip ( )
182
182
}
183
183
184
184
ipfs . files . mv ( [ '/test/lv1/404' , '/test/lv1' ] , ( err ) => {
@@ -187,10 +187,10 @@ module.exports = (common) => {
187
187
} )
188
188
} )
189
189
190
- it ( 'move dir, expect no error' , ( done ) => {
190
+ it ( 'move dir, expect no error' , function ( done ) {
191
191
if ( ! withGo ) {
192
192
console . log ( 'Not supported in js-ipfs yet' )
193
- return done ( )
193
+ this . skip ( )
194
194
}
195
195
196
196
ipfs . files . mv ( [ '/test/lv1/lv2' , '/test/lv1/lv4' ] , ( err ) => {
@@ -201,10 +201,10 @@ module.exports = (common) => {
201
201
} )
202
202
203
203
describe ( '.rm' , function ( ) {
204
- it ( 'remove file, expect error' , ( done ) => {
204
+ it ( 'remove file, expect error' , function ( done ) {
205
205
if ( ! withGo ) {
206
206
console . log ( 'Not supported in js-ipfs yet' )
207
- return done ( )
207
+ this . skip ( )
208
208
}
209
209
210
210
ipfs . files . rm ( '/test/a' , ( err ) => {
@@ -213,10 +213,10 @@ module.exports = (common) => {
213
213
} )
214
214
} )
215
215
216
- it ( 'remove file, expect no error' , ( done ) => {
216
+ it ( 'remove file, expect no error' , function ( done ) {
217
217
if ( ! withGo ) {
218
218
console . log ( 'Not supported in js-ipfs yet' )
219
- return done ( )
219
+ this . skip ( )
220
220
}
221
221
222
222
ipfs . files . rm ( '/test/c' , ( err ) => {
@@ -225,10 +225,10 @@ module.exports = (common) => {
225
225
} )
226
226
} )
227
227
228
- it ( 'remove dir, expect error' , ( done ) => {
228
+ it ( 'remove dir, expect error' , function ( done ) {
229
229
if ( ! withGo ) {
230
230
console . log ( 'Not supported in js-ipfs yet' )
231
- return done ( )
231
+ this . skip ( )
232
232
}
233
233
234
234
ipfs . files . rm ( '/test/lv1/lv4' , ( err ) => {
@@ -237,10 +237,10 @@ module.exports = (common) => {
237
237
} )
238
238
} )
239
239
240
- it ( 'remove dir, expect no error' , ( done ) => {
240
+ it ( 'remove dir, expect no error' , function ( done ) {
241
241
if ( ! withGo ) {
242
242
console . log ( 'Not supported in js-ipfs yet' )
243
- return done ( )
243
+ this . skip ( )
244
244
}
245
245
246
246
ipfs . files . rm ( '/test/lv1/lv4' , { recursive : true } , ( err ) => {
@@ -251,10 +251,10 @@ module.exports = (common) => {
251
251
} )
252
252
253
253
describe ( '.stat' , function ( ) {
254
- it ( 'stat not found, expect error' , ( done ) => {
254
+ it ( 'stat not found, expect error' , function ( done ) {
255
255
if ( ! withGo ) {
256
256
console . log ( 'Not supported in js-ipfs yet' )
257
- return done ( )
257
+ this . skip ( )
258
258
}
259
259
260
260
ipfs . files . stat ( '/test/404' , ( err ) => {
@@ -263,10 +263,10 @@ module.exports = (common) => {
263
263
} )
264
264
} )
265
265
266
- it ( 'stat file' , ( done ) => {
266
+ it ( 'stat file' , function ( done ) {
267
267
if ( ! withGo ) {
268
268
console . log ( 'Not supported in js-ipfs yet' )
269
- return done ( )
269
+ this . skip ( )
270
270
}
271
271
272
272
ipfs . files . stat ( '/test/b' , ( err , stat ) => {
@@ -282,10 +282,10 @@ module.exports = (common) => {
282
282
} )
283
283
} )
284
284
285
- it ( 'stat dir' , ( done ) => {
285
+ it ( 'stat dir' , function ( done ) {
286
286
if ( ! withGo ) {
287
287
console . log ( 'Not supported in js-ipfs yet' )
288
- return done ( )
288
+ this . skip ( )
289
289
}
290
290
291
291
ipfs . files . stat ( '/test' , ( err , stat ) => {
@@ -303,10 +303,10 @@ module.exports = (common) => {
303
303
} )
304
304
305
305
describe ( '.read' , function ( ) {
306
- it ( 'read not found, expect error' , ( done ) => {
306
+ it ( 'read not found, expect error' , function ( done ) {
307
307
if ( ! withGo ) {
308
308
console . log ( 'Not supported in js-ipfs yet' )
309
- return done ( )
309
+ this . skip ( )
310
310
}
311
311
312
312
ipfs . files . read ( '/test/404' , ( err , buf ) => {
@@ -316,10 +316,10 @@ module.exports = (common) => {
316
316
} )
317
317
} )
318
318
319
- it ( 'read file' , ( done ) => {
319
+ it ( 'read file' , function ( done ) {
320
320
if ( ! withGo ) {
321
321
console . log ( 'Not supported in js-ipfs yet' )
322
- return done ( )
322
+ this . skip ( )
323
323
}
324
324
325
325
ipfs . files . read ( '/test/b' , ( err , buf ) => {
@@ -331,10 +331,10 @@ module.exports = (common) => {
331
331
} )
332
332
333
333
describe ( '.ls' , function ( ) {
334
- it ( 'ls not found, expect error' , ( done ) => {
334
+ it ( 'ls not found, expect error' , function ( done ) {
335
335
if ( ! withGo ) {
336
336
console . log ( 'Not supported in js-ipfs yet' )
337
- return done ( )
337
+ this . skip ( )
338
338
}
339
339
340
340
ipfs . files . ls ( '/test/404' , ( err , info ) => {
@@ -344,10 +344,10 @@ module.exports = (common) => {
344
344
} )
345
345
} )
346
346
347
- it ( 'ls directory' , ( done ) => {
347
+ it ( 'ls directory' , function ( done ) {
348
348
if ( ! withGo ) {
349
349
console . log ( 'Not supported in js-ipfs yet' )
350
- return done ( )
350
+ this . skip ( )
351
351
}
352
352
353
353
ipfs . files . ls ( '/test' , ( err , info ) => {
@@ -360,10 +360,10 @@ module.exports = (common) => {
360
360
} )
361
361
} )
362
362
363
- it ( 'ls -l directory' , ( done ) => {
363
+ it ( 'ls -l directory' , function ( done ) {
364
364
if ( ! withGo ) {
365
365
console . log ( 'Not supported in js-ipfs yet' )
366
- return done ( )
366
+ this . skip ( )
367
367
}
368
368
369
369
ipfs . files . ls ( '/test' , { l : true } , ( err , info ) => {
@@ -388,10 +388,10 @@ module.exports = (common) => {
388
388
} )
389
389
390
390
describe ( '.flush' , function ( ) {
391
- it ( 'flush not found, expect error' , ( done ) => {
391
+ it ( 'flush not found, expect error' , function ( done ) {
392
392
if ( ! withGo ) {
393
393
console . log ( 'Not supported in js-ipfs yet' )
394
- return done ( )
394
+ this . skip ( )
395
395
}
396
396
397
397
ipfs . files . flush ( '/test/404' , ( err ) => {
@@ -400,10 +400,10 @@ module.exports = (common) => {
400
400
} )
401
401
} )
402
402
403
- it ( 'flush root' , ( done ) => {
403
+ it ( 'flush root' , function ( done ) {
404
404
if ( ! withGo ) {
405
405
console . log ( 'Not supported in js-ipfs yet' )
406
- return done ( )
406
+ this . skip ( )
407
407
}
408
408
409
409
ipfs . files . flush ( ( err ) => {
@@ -412,10 +412,10 @@ module.exports = (common) => {
412
412
} )
413
413
} )
414
414
415
- it ( 'flush specific dir' , ( done ) => {
415
+ it ( 'flush specific dir' , function ( done ) {
416
416
if ( ! withGo ) {
417
417
console . log ( 'Not supported in js-ipfs yet' )
418
- return done ( )
418
+ this . skip ( )
419
419
}
420
420
421
421
ipfs . files . flush ( '/test' , ( err ) => {
0 commit comments