|
21 | 21 | // MODULES // |
22 | 22 |
|
23 | 23 | var tape = require( 'tape' ); |
24 | | -var isUint32Array = require( '@stdlib/assert-is-uint32array' ); |
25 | | -var random = require( './../../dist' ); |
| 24 | +var main = require( './../../dist' ); |
26 | 25 |
|
27 | 26 |
|
28 | 27 | // TESTS // |
29 | 28 |
|
30 | | -tape( 'main export is a function', function test( t ) { |
| 29 | +tape( 'main export is defined', function test( t ) { |
31 | 30 | t.ok( true, __filename ); |
32 | | - t.strictEqual( typeof random, 'function', 'main export is a function' ); |
33 | | - t.end(); |
34 | | -}); |
35 | | - |
36 | | -tape( 'attached to the main export is a `factory` method', function test( t ) { |
37 | | - t.strictEqual( typeof random.factory, 'function', 'has method' ); |
38 | | - t.end(); |
39 | | -}); |
40 | | - |
41 | | -tape( 'attached to the main export is the underlying PRNG', function test( t ) { |
42 | | - t.equal( typeof random.PRNG, 'function', 'has property' ); |
43 | | - t.end(); |
44 | | -}); |
45 | | - |
46 | | -tape( 'attached to the main export is the generator seed', function test( t ) { |
47 | | - t.equal( isUint32Array( random.seed ), true, 'has property' ); |
48 | | - t.end(); |
49 | | -}); |
50 | | - |
51 | | -tape( 'attached to the main export is the generator seed length', function test( t ) { |
52 | | - t.equal( typeof random.seedLength, 'number', 'has property' ); |
53 | | - t.end(); |
54 | | -}); |
55 | | - |
56 | | -tape( 'attached to the main export is the generator state', function test( t ) { |
57 | | - t.equal( isUint32Array( random.state ), true, 'has property' ); |
58 | | - t.end(); |
59 | | -}); |
60 | | - |
61 | | -tape( 'attached to the main export is the generator state length', function test( t ) { |
62 | | - t.equal( typeof random.stateLength, 'number', 'has property' ); |
63 | | - t.end(); |
64 | | -}); |
65 | | - |
66 | | -tape( 'attached to the main export is the generator state size', function test( t ) { |
67 | | - t.equal( typeof random.byteLength, 'number', 'has property' ); |
| 31 | + t.strictEqual( main !== void 0, true, 'main export is defined' ); |
68 | 32 | t.end(); |
69 | 33 | }); |
0 commit comments