File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -57,9 +57,14 @@ function jsonScriptTest(jsInterpreters, opts) {
5757
5858 function testResult ( res ) {
5959 if ( test . result !== undefined ) {
60- var method = typeof res == 'object' && res !== null
61- ? 'deepStrictEqual'
62- : 'strictEqual' ;
60+ var method ;
61+ if ( typeof res == 'object' && res !== null ) {
62+ method = 'deepStrictEqual' ;
63+ res = JSON . parse ( JSON . stringify ( res ) ) ;
64+ } else {
65+ method = 'strictEqual' ;
66+ }
67+
6368 try {
6469 assert [ method ] ( res , test . result ) ;
6570 suiteHooks ( true , res ) ;
Original file line number Diff line number Diff line change 11{
22 "name" : " jsonscript-test" ,
3- "version" : " 0.2.0 " ,
3+ "version" : " 0.2.1 " ,
44 "description" : " Testing JSONScript scripts using test suites" ,
55 "main" : " index.js" ,
66 "scripts" : {
2323 "dependencies" : {
2424 "ajv" : " ^3.7.0" ,
2525 "glob" : " ^7.0.0" ,
26- "jsonscript" : " ^0.2.0 " ,
27- "jsonscript-test-suite" : " ^0.1.0 "
26+ "jsonscript" : " ^0.2.2 " ,
27+ "jsonscript-test-suite" : " ^0.2.2 "
2828 }
2929}
You can’t perform that action at this time.
0 commit comments