File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed
packages/compass-schema/src/stores Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -178,11 +178,12 @@ describe('Schema Store', function () {
178178 expect ( exportStatus ) . to . equal ( 'complete' ) ;
179179 expect ( ! ! errorMessage ) . to . be . false ;
180180 expect ( exportedSchema ) . not . to . be . undefined ;
181- expect ( JSON . parse ( exportedSchema ! ) . type ) . to . equal ( undefined ) ;
182- expect ( JSON . parse ( exportedSchema ! ) . bsonType ) . to . equal ( 'object' ) ;
183- expect ( JSON . parse ( exportedSchema ! ) [ '$schema' ] ) . to . equal ( undefined ) ;
184- expect ( JSON . parse ( exportedSchema ! ) . required ) . to . deep . equal ( [ 'name' ] ) ;
185- expect ( JSON . parse ( exportedSchema ! ) . properties ) . to . deep . equal ( {
181+ const parsedSchema = JSON . parse ( exportedSchema ! ) . $jsonSchema ;
182+ expect ( parsedSchema . type ) . to . equal ( undefined ) ;
183+ expect ( parsedSchema . bsonType ) . to . equal ( 'object' ) ;
184+ expect ( parsedSchema [ '$schema' ] ) . to . equal ( undefined ) ;
185+ expect ( parsedSchema . required ) . to . deep . equal ( [ 'name' ] ) ;
186+ expect ( parsedSchema . properties ) . to . deep . equal ( {
186187 name : { bsonType : 'string' } ,
187188 } ) ;
188189 expect ( filename ) . to . equal ( 'schema-db-coll-mongoDBJSON.json' ) ;
You can’t perform that action at this time.
0 commit comments