2323var tape = require ( 'tape' ) ;
2424var hasSymbolSupport = require ( '@stdlib/assert/has-symbol-support' ) ;
2525var Symbol = require ( '@stdlib/symbol/ctor' ) ;
26- var assign = require ( './../lib' ) ;
26+ var assign = require ( './../lib/builtin.js ' ) ;
2727
2828
2929// VARIABLES //
3030
3131var opts = {
32- 'skip' : ! hasSymbolSupport ( )
32+ 'skip' : ( typeof Object . assign === 'undefined' ) // eslint-disable-line node/no-unsupported-features/es-builtins
33+ } ;
34+ var optsSymbool = {
35+ 'skip' : opts . skip || ! hasSymbolSupport ( )
3336} ;
3437
3538
3639// TESTS //
3740
38- tape ( 'main export is a function' , function test ( t ) {
39- t . ok ( typeof assign === 'function' , 'main export is a function' ) ;
41+ tape ( 'main export is a function' , opts , function test ( t ) {
42+ t . ok ( true , __filename ) ;
43+ t . strictEqual ( typeof assign , 'function' , 'main export is a function' ) ;
4044 t . end ( ) ;
4145} ) ;
4246
43- tape ( 'the function throws an error if provided `undefined` or `null` as a target object' , function test ( t ) {
47+ tape ( 'the function throws an error if provided `undefined` or `null` as a target object' , opts , function test ( t ) {
4448 var values ;
4549 var i ;
4650
@@ -61,7 +65,7 @@ tape( 'the function throws an error if provided `undefined` or `null` as a targe
6165 }
6266} ) ;
6367
64- tape ( 'the function returns the target object' , function test ( t ) {
68+ tape ( 'the function returns the target object' , opts , function test ( t ) {
6569 var out ;
6670 var obj ;
6771
@@ -74,7 +78,7 @@ tape( 'the function returns the target object', function test( t ) {
7478 t . end ( ) ;
7579} ) ;
7680
77- tape ( 'the function assigns enumerable own properties of one or more source objects to a target object' , function test ( t ) {
81+ tape ( 'the function assigns enumerable own properties of one or more source objects to a target object' , opts , function test ( t ) {
7882 var expected ;
7983 var obj1 ;
8084 var obj2 ;
@@ -103,7 +107,7 @@ tape( 'the function assigns enumerable own properties of one or more source obje
103107 t . end ( ) ;
104108} ) ;
105109
106- tape ( 'the function copies symbol-typed properties' , opts , function test ( t ) {
110+ tape ( 'the function copies symbol-typed properties' , optsSymbool , function test ( t ) {
107111 var expected ;
108112 var obj1 ;
109113 var obj2 ;
@@ -125,11 +129,12 @@ tape( 'the function copies symbol-typed properties', opts, function test( t ) {
125129 } ;
126130 expected [ sym ] = 'boop' ;
127131
128- t . deepEqual ( out , expected , 'returns expected object' ) ;
132+ t . strictEqual ( out [ sym ] , expected [ sym ] , 'returns expected object' ) ;
133+ t . strictEqual ( out . a , expected . a , 'returns expected object' ) ;
129134 t . end ( ) ;
130135} ) ;
131136
132- tape ( 'the function wraps primitives to objects' , function test ( t ) {
137+ tape ( 'the function wraps source primitives as objects before assignment' , opts , function test ( t ) {
133138 var expected ;
134139 var obj1 ;
135140 var obj2 ;
0 commit comments