@@ -15,39 +15,41 @@ const dirtyChai = require('dirty-chai')
15
15
const expect = chai . expect
16
16
chai . use ( dirtyChai )
17
17
18
- describe ( '.types' , function ( ) {
19
- let ipfs
18
+ module . exports = ( common ) => {
19
+ describe ( '.types' , function ( ) {
20
+ let ipfs
20
21
21
- before ( function ( done ) {
22
- // CI takes longer to instantiate the daemon, so we need to increase the
23
- // timeout for the before step
24
- this . timeout ( 60 * 1000 )
22
+ before ( function ( done ) {
23
+ // CI takes longer to instantiate the daemon, so we need to increase the
24
+ // timeout for the before step
25
+ this . timeout ( 60 * 1000 )
25
26
26
- common . setup ( ( err , factory ) => {
27
- expect ( err ) . to . not . exist ( )
28
- factory . spawnNode ( ( err , node ) => {
27
+ common . setup ( ( err , factory ) => {
29
28
expect ( err ) . to . not . exist ( )
30
- ipfs = node
31
- done ( )
29
+ factory . spawnNode ( ( err , node ) => {
30
+ expect ( err ) . to . not . exist ( )
31
+ ipfs = node
32
+ done ( )
33
+ } )
32
34
} )
33
35
} )
34
- } )
35
36
36
- after ( ( done ) => {
37
- common . teardown ( done )
38
- } )
37
+ after ( ( done ) => {
38
+ common . teardown ( done )
39
+ } )
39
40
40
- it ( 'types object' , ( ) => {
41
- expect ( ipfs . types ) . to . be . deep . equal ( {
42
- Buffer : Buffer ,
43
- PeerId : PeerId ,
44
- PeerInfo : PeerInfo ,
45
- multiaddr : multiaddr ,
46
- multibase : multibase ,
47
- multihash : multihash ,
48
- CID : CID ,
49
- dagPB : dagPB ,
50
- dagCBOR : dagCBOR
41
+ it ( 'types object' , ( ) => {
42
+ expect ( ipfs . types ) . to . be . deep . equal ( {
43
+ Buffer : Buffer ,
44
+ PeerId : PeerId ,
45
+ PeerInfo : PeerInfo ,
46
+ multiaddr : multiaddr ,
47
+ multibase : multibase ,
48
+ multihash : multihash ,
49
+ CID : CID ,
50
+ dagPB : dagPB ,
51
+ dagCBOR : dagCBOR
52
+ } )
51
53
} )
52
54
} )
53
- } )
55
+ }
0 commit comments