Skip to content

Commit 8d7843a

Browse files
committed
Add removed Babel test back
1 parent 216a5ca commit 8d7843a

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

Diff for: test/functional.js

+16
Original file line numberDiff line numberDiff line change
@@ -1075,6 +1075,22 @@ module.exports = {
10751075
});
10761076
});
10771077

1078+
it('Babel is executed on .js files', (done) => {
1079+
const config = createWebpackConfig('www/build', 'dev');
1080+
config.setPublicPath('/build');
1081+
config.addEntry('main', './js/class-syntax');
1082+
1083+
testSetup.runWebpack(config, (webpackAssert) => {
1084+
// check that babel transformed the class
1085+
webpackAssert.assertOutputFileDoesNotContain(
1086+
'main.js',
1087+
'class A {}'
1088+
);
1089+
1090+
done();
1091+
});
1092+
});
1093+
10781094
it('Babel can be configured via .babelrc', (done) => {
10791095
// create the .babelrc file first, so we see it
10801096
const appDir = testSetup.createTestAppDir();

0 commit comments

Comments
 (0)