first commit
This commit is contained in:
97
test/fixtures/core/regression/T2921/expected.json
vendored
Normal file
97
test/fixtures/core/regression/T2921/expected.json
vendored
Normal file
@@ -0,0 +1,97 @@
|
||||
{
|
||||
"type": "File",
|
||||
"start": 0,
|
||||
"end": 8,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 8
|
||||
}
|
||||
},
|
||||
"program": {
|
||||
"type": "Program",
|
||||
"start": 0,
|
||||
"end": 8,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 8
|
||||
}
|
||||
},
|
||||
"sourceType": "script",
|
||||
"body": [
|
||||
{
|
||||
"type": "ExpressionStatement",
|
||||
"start": 0,
|
||||
"end": 8,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 8
|
||||
}
|
||||
},
|
||||
"expression": {
|
||||
"type": "BinaryExpression",
|
||||
"start": 0,
|
||||
"end": 7,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 7
|
||||
}
|
||||
},
|
||||
"left": {
|
||||
"type": "Identifier",
|
||||
"start": 0,
|
||||
"end": 1,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 0
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 1
|
||||
}
|
||||
},
|
||||
"name": "a"
|
||||
},
|
||||
"operator": "<==",
|
||||
"right": {
|
||||
"type": "Identifier",
|
||||
"start": 6,
|
||||
"end": 7,
|
||||
"loc": {
|
||||
"start": {
|
||||
"line": 1,
|
||||
"column": 6
|
||||
},
|
||||
"end": {
|
||||
"line": 1,
|
||||
"column": 7
|
||||
}
|
||||
},
|
||||
"name": "b"
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"directives": []
|
||||
}
|
||||
}
|
||||
@@ -1,21 +1,20 @@
|
||||
var getFixtures = require("babel-helper-fixtures").multiple;
|
||||
var parse = require("../lib").parse;
|
||||
var test = require("ava");
|
||||
var _ = require("lodash");
|
||||
|
||||
var fixtures = getFixtures(__dirname + "/fixtures");
|
||||
|
||||
_.each(fixtures, function (suites, name) {
|
||||
_.each(suites, function (testSuite) {
|
||||
suite(name + "/" + testSuite.title, function () {
|
||||
_.each(testSuite.tests, function (task) {
|
||||
test(task.title, !task.disabled && function () {
|
||||
try {
|
||||
return runTest(task);
|
||||
} catch (err) {
|
||||
err.message = task.actual.loc + ": " + err.message;
|
||||
throw err;
|
||||
}
|
||||
});
|
||||
_.each(testSuite.tests, function (task) {
|
||||
test(name + "/" + testSuite.title + "/" + task.title, !task.disabled && function () {
|
||||
try {
|
||||
return runTest(task);
|
||||
} catch (err) {
|
||||
err.message = task.actual.loc + ": " + err.message;
|
||||
throw err;
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user