11/* eslint-env mocha */
2+ /* eslint max-nested-callbacks: ["error", 8] */
23/* globals apiClients */
4+
35'use strict'
46
57const expect = require ( 'chai' ) . expect
68const isNode = require ( 'detect-node' )
79const fs = require ( 'fs' )
8- const bl = require ( 'bl' )
10+ // const bl = require('bl')
911const concat = require ( 'concat-stream' )
1012const through = require ( 'through2' )
13+ const streamEqual = require ( 'stream-equal' )
1114
1215const path = require ( 'path' )
13- const streamEqual = require ( 'stream-equal' )
1416
15- const extract = require ( 'tar-stream' ) . extract
17+ // const extract = require('tar-stream').extract
1618
17- let testfile
19+ const testfile = fs . readFileSync ( path . join ( __dirname , '/../testfile.txt' ) )
1820let testfileBig
1921
2022if ( isNode ) {
21- testfile = fs . readFileSync ( path . join ( __dirname , '/../testfile.txt' ) )
2223 testfileBig = fs . createReadStream ( path . join ( __dirname , '/../15mb.random' ) , { bufferSize : 128 } )
23- } else {
24- testfile = require ( 'raw!../testfile.txt' )
2524}
2625
27- describe ( '.get' , ( ) => {
26+ describe . skip ( '.get' , ( ) => {
2827 it ( 'get with no compression args' , ( done ) => {
2928 apiClients . a
3029 . get ( 'Qma4hjFTnCasJ8PVp3mZbZK5g2vGDT4LByLJ7m8ciyRFZP' , ( err , res ) => {
30+ expect ( err ) . to . not . exist
3131
3232 // accumulate the files and their content
3333 var files = [ ]
@@ -50,6 +50,7 @@ describe('.get', () => {
5050 it ( 'get with archive true' , ( done ) => {
5151 apiClients . a
5252 . get ( 'Qma4hjFTnCasJ8PVp3mZbZK5g2vGDT4LByLJ7m8ciyRFZP' , { archive : true } , ( err , res ) => {
53+ expect ( err ) . to . not . exist
5354
5455 // accumulate the files and their content
5556 var files = [ ]
@@ -86,7 +87,7 @@ describe('.get', () => {
8687 } )
8788 } )
8889
89- it . skip ( 'get BIG file' , ( done ) => {
90+ it ( 'get BIG file' , ( done ) => {
9091 if ( ! isNode ) {
9192 return done ( )
9293 }
@@ -103,9 +104,9 @@ describe('.get', () => {
103104 } )
104105 } )
105106
106- describe ( 'promise' , ( ) => {
107- it . skip ( 'get' , ( done ) => {
108- return apiClients . a . get ( 'Qma4hjFTnCasJ8PVp3mZbZK5g2vGDT4LByLJ7m8ciyRFZP' )
107+ describe . skip ( 'promise' , ( ) => {
108+ it ( 'get' , ( done ) => {
109+ apiClients . a . get ( 'Qma4hjFTnCasJ8PVp3mZbZK5g2vGDT4LByLJ7m8ciyRFZP' )
109110 . then ( ( res ) => {
110111 let buf = ''
111112 res
0 commit comments