@@ -185,7 +185,7 @@ module.exports = (common) => {
185
185
const hash = 'QmPZ9gcCEpqKTo6aq61g2nXGUhM4iCL3ewB6LDXZCtioEB'
186
186
ipfs . cat ( hash , ( err , stream ) => {
187
187
expect ( err ) . to . not . exist
188
- stream . pipe ( bl ( ( err , data ) => {
188
+ stream . pipe ( concat ( ( data ) => {
189
189
expect ( err ) . to . not . exist
190
190
expect ( data . toString ( ) ) . to . contain ( 'Check out some of the other files in this directory:' )
191
191
done ( )
@@ -197,21 +197,23 @@ module.exports = (common) => {
197
197
const hash = 'Qme79tX2bViL26vNjPsF3DP1R9rMKMvnPYJiKTTKPrXJjq'
198
198
ipfs . cat ( hash , ( err , stream ) => {
199
199
expect ( err ) . to . not . exist
200
- stream . pipe ( bl ( ( err , data ) => {
200
+ stream . pipe ( concat ( ( data ) => {
201
201
expect ( err ) . to . not . exist
202
202
expect ( data ) . to . deep . equal ( bigFile )
203
203
done ( )
204
204
} ) )
205
205
} )
206
+ } )
206
207
207
- it ( 'with a multihash' , ( done ) => {
208
- const mhBuf = new Buffer ( bs58 . decode ( 'QmPZ9gcCEpqKTo6aq61g2nXGUhM4iCL3ewB6LDXZCtioEB' ) )
209
- ipfs . cat ( mhBuf , ( err , stream ) => {
210
- expect ( err ) . to . not . exist
211
- stream . pipe ( concat ( ( data ) => {
212
- expect ( data . toString ( ) ) . to . contain ( 'Check out some of the other files in this directory:' )
213
- done ( )
214
- } ) )
208
+ it ( 'with a multihash' , ( done ) => {
209
+ const mhBuf = new Buffer ( bs58 . decode ( 'QmPZ9gcCEpqKTo6aq61g2nXGUhM4iCL3ewB6LDXZCtioEB' ) )
210
+ ipfs . cat ( mhBuf , ( err , stream ) => {
211
+ expect ( err ) . to . not . exist
212
+ stream . pipe ( concat ( ( data ) => {
213
+ expect ( data . toString ( ) ) . to . contain ( 'Check out some of the other files in this directory:' )
214
+ done ( )
215
+ } ) )
216
+ } )
215
217
} )
216
218
} )
217
219
} )
@@ -306,7 +308,7 @@ module.exports = (common) => {
306
308
expect ( err ) . to . not . exist
307
309
stream . pipe ( concat ( ( files ) => {
308
310
expect ( files ) . to . be . length ( 1 )
309
- expect ( files [ 0 ] . path ) . to . deep . equal ( hash )
311
+ expect ( files [ 0 ] . path ) . to . deep . equal ( mhBuf )
310
312
files [ 0 ] . content . pipe ( concat ( ( content ) => {
311
313
expect ( content . toString ( ) ) . to . contain ( 'Check out some of the other files in this directory:' )
312
314
done ( )
0 commit comments