@@ -24,21 +24,21 @@ describe('bufferToSerializedFormat', () => {
24
24
25
25
describe ( KeyValueFormat . Vector32Bit , ( ) => {
26
26
describe ( 'should properly serialize' , ( ) => {
27
- const testValues = [ new Float32Array ( [ 1.0 , 2.0 ] ) , new Float32Array ( [ 12.12 , 13.41 ] ) ] . map ( ( v ) => {
28
- input: anyToBuffer ( v . buffer )
29
- expected: JSON . stringify ( v )
30
- } )
27
+ const testValues = [ new Float32Array ( [ 1.0 , 2.0 ] ) , new Float32Array ( [ 12.12 , 13.41 ] ) ] . map ( ( v ) => ( {
28
+ input : anyToBuffer ( v . buffer ) ,
29
+ expected : JSON . stringify ( v ) ,
30
+ } ) )
31
31
32
32
test . each ( testValues ) ( 'test %j' , ( { input, expected } ) => {
33
33
expect ( JSON . stringify ( bufferToSerializedFormat ( KeyValueFormat . Vector32Bit , input ) ) ) . toEqual ( expected )
34
34
} )
35
35
} )
36
36
37
37
describe ( 'should properly return value with invalid values' , ( ) => {
38
- const testValues = [ new Float32Array ( [ 'test' ] ) ] . map ( ( v ) => {
39
- input: anyToBuffer ( v . buffer )
40
- expected: JSON . stringify ( v )
41
- } )
38
+ const testValues = [ new Float32Array ( [ 'test' ] ) ] . map ( ( v ) => ( {
39
+ input : anyToBuffer ( v . buffer ) ,
40
+ expected : JSON . stringify ( v ) ,
41
+ } ) )
42
42
43
43
test . each ( testValues ) ( 'test %j' , ( { input, expected } ) => {
44
44
expect ( JSON . stringify ( bufferToSerializedFormat ( KeyValueFormat . Vector32Bit , input ) ) ) . toEqual ( expected )
@@ -48,21 +48,21 @@ describe('bufferToSerializedFormat', () => {
48
48
49
49
describe ( KeyValueFormat . Vector64Bit , ( ) => {
50
50
describe ( 'should properly serialize' , ( ) => {
51
- const testValues = [ new Float64Array ( [ 1.0 , 2.0 ] ) , new Float64Array ( [ 12.12 , 13.41 ] ) ] . map ( ( v ) => {
52
- input: anyToBuffer ( v . buffer )
53
- expected: JSON . stringify ( v )
54
- } )
51
+ const testValues = [ new Float64Array ( [ 1.0 , 2.0 ] ) , new Float64Array ( [ 12.12 , 13.41 ] ) ] . map ( ( v ) => ( {
52
+ input : anyToBuffer ( v . buffer ) ,
53
+ expected : JSON . stringify ( v ) ,
54
+ } ) )
55
55
56
56
test . each ( testValues ) ( 'test %j' , ( { input, expected } ) => {
57
57
expect ( JSON . stringify ( bufferToSerializedFormat ( KeyValueFormat . Vector64Bit , input ) ) ) . toEqual ( expected )
58
58
} )
59
59
} )
60
60
61
61
describe ( 'should properly return value with invalid values' , ( ) => {
62
- const testValues = [ new Float64Array ( [ 'test' ] ) ] . map ( ( v ) => {
63
- input: anyToBuffer ( v . buffer )
64
- expected: JSON . stringify ( v )
65
- } )
62
+ const testValues = [ new Float64Array ( [ 'test' ] ) ] . map ( ( v ) => ( {
63
+ input : anyToBuffer ( v . buffer ) ,
64
+ expected : JSON . stringify ( v ) ,
65
+ } ) )
66
66
67
67
test . each ( testValues ) ( 'test %j' , ( { input, expected } ) => {
68
68
expect ( JSON . stringify ( bufferToSerializedFormat ( KeyValueFormat . Vector64Bit , input ) ) ) . toEqual ( expected )
0 commit comments