Add test for T2765
This commit is contained in:
parent
bbc3401c71
commit
57c6c4ea81
5
packages/babel-core/test/fixtures/transformation/misc/regression-2765/actual.js
vendored
Normal file
5
packages/babel-core/test/fixtures/transformation/misc/regression-2765/actual.js
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
function f() {
|
||||
let g = async () => {
|
||||
this;
|
||||
};
|
||||
};
|
||||
12
packages/babel-core/test/fixtures/transformation/misc/regression-2765/expected.js
vendored
Normal file
12
packages/babel-core/test/fixtures/transformation/misc/regression-2765/expected.js
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
function f() {
|
||||
var _this = this;
|
||||
|
||||
let g = function () {
|
||||
var ref = babelHelpers.asyncToGenerator(function* () {
|
||||
_this;
|
||||
});
|
||||
return function g() {
|
||||
return ref.apply(this, arguments);
|
||||
};
|
||||
}();
|
||||
};
|
||||
8
packages/babel-core/test/fixtures/transformation/misc/regression-2765/options.json
vendored
Normal file
8
packages/babel-core/test/fixtures/transformation/misc/regression-2765/options.json
vendored
Normal file
@ -0,0 +1,8 @@
|
||||
{
|
||||
"plugins": [
|
||||
"transform-es2015-arrow-functions",
|
||||
"syntax-async-functions",
|
||||
"transform-async-to-generator",
|
||||
"external-helpers"
|
||||
]
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user