Fix tests & a typo

This commit is contained in:
Christopher Willis-Ford 2017-11-03 11:42:20 -07:00
parent 0af3de9bf0
commit c88a8fa55a
5 changed files with 7 additions and 7 deletions

View file

@ -20,7 +20,7 @@ test('default', t => {
// Create runtime instance & load SB2 into it
const rt = new Runtime();
sb2.deserialize(json, rt).then(targets => {
sb2.deserialize(json, rt).then(({targets}) => {
// Test
t.type(file, 'string');
t.type(json, 'object');
@ -60,7 +60,7 @@ test('data scoping', t => {
// Create runtime instance & load SB2 into it
const rt = new Runtime();
sb2.deserialize(json, rt).then(targets => {
sb2.deserialize(json, rt).then(({targets}) => {
const globalVariableIds = Object.keys(targets[0].variables);
const localVariableIds = Object.keys(targets[1].variables);
t.equal(targets[0].variables[globalVariableIds[0]].name, 'foo');