Skip to content

Commit a9e8a7b

Browse files
committed
Add test for number and boolean types
1 parent 476af1c commit a9e8a7b

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/routes/+page.svelte

+3-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,9 @@ const fixture = [
6363
empty_string: '',
6464
empty_obj: {},
6565
empty_arr: [],
66-
escaped: `"`
66+
escaped: `"`,
67+
number: 200,
68+
boolean: true
6769
}
6870
]
6971
const fixture2 = 'test invalid object'

tests/test.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ test('special types', async ({ page }) => {
2828
'null',
2929
'undefined',
3030
'""',
31-
'"\\""'
31+
'"\\""',
32+
'200',
33+
'true'
3234
]
3335
for (let a = 0; a < list.length; a++) {
3436
expect(list[a]).toStrictEqual(asserts[a])

0 commit comments

Comments
 (0)