Skip to content

Commit

Permalink
Merge pull request #304 from johnnyreilly/master
Browse files Browse the repository at this point in the history
Upgraded dependencies (including babel 5 -> 6) #197
  • Loading branch information
johnnyreilly authored Oct 9, 2016
2 parents ceee6e7 + 0c21a07 commit 9482255
Show file tree
Hide file tree
Showing 19 changed files with 51 additions and 52 deletions.
15 changes: 9 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,18 +32,21 @@
"colors": "^1.0.3",
"enhanced-resolve": "^0.9.0",
"loader-utils": "^0.2.6",
"object-assign": "^2.0.0",
"object-assign": "^4.1.0",
"semver": "^5.0.1"
},
"devDependencies": {
"babel-core": "^5.8.20",
"babel-loader": "^5.3.2",
"babel": "^6.0.0",
"babel-core": "^6.0.0",
"babel-loader": "^6.0.0",
"babel-preset-es2015": "^6.0.0",
"babel-preset-react": "^6.0.0",
"escape-string-regexp": "^1.0.3",
"fs-extra": "^0.22.1",
"glob": "^6.0.3",
"fs-extra": "^0.30.0",
"glob": "^7.1.1",
"html-webpack-plugin": "^2.17.0",
"mkdirp": "^0.5.1",
"mocha": "^2.1.0",
"mocha": "^3.1.0",
"rimraf": "^2.4.2",
"typescript": "^2.0.3",
"webpack": "^1.11.0"
Expand Down
4 changes: 1 addition & 3 deletions test/es6resolveParent/expectedOutput-2.0/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,9 @@

function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }

var BaseComponent = function BaseComponent() {
var BaseComponent = exports.BaseComponent = function BaseComponent() {
_classCallCheck(this, BaseComponent);
};

exports.BaseComponent = BaseComponent;

/***/ }
/******/ ]);
6 changes: 3 additions & 3 deletions test/es6resolveParent/expectedOutput-2.0/output.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Asset Size Chunks Chunk Names
bundle.js 1.76 kB 0 [emitted] main
chunk {0} bundle.js (main) 365 bytes [rendered]
[0] ./.test/es6resolveParent/index.tsx 365 bytes {0} [built]
bundle.js 1.74 kB 0 [emitted] main
chunk {0} bundle.js (main) 349 bytes [rendered]
[0] ./.test/es6resolveParent/index.tsx 349 bytes {0} [built]
2 changes: 1 addition & 1 deletion test/es6resolveParent/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = {
},
module: {
loaders: [
{ test: /\.tsx?$/, loader: 'babel-loader!ts-loader' }
{ test: /\.tsx?$/, loader: 'babel-loader?presets[]=es2015&presets[]=react!ts-loader' }
]
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ Child html-webpack-plugin for "index.html":
Asset Size Chunks Chunk Names
index.html 553 kB 0
chunk {0} index.html 536 kB [rendered]
[0] ./~/html-webpack-plugin/lib/loader.js!./~/html-webpack-plugin/default_index.ejs 550 bytes {0} [built]
[1] ./~/html-webpack-plugin/~/lodash/lodash.js 535 kB {0} [built]
[0] ./~/html-webpack-plugin/lib/loader.js!./~/html-webpack-plugin/default_index.ejs 540 bytes {0} [built]
[1] ./~/lodash/lodash.js 535 kB {0} [built]
[2] (webpack)/buildin/module.js 241 bytes {0} [built]
4 changes: 2 additions & 2 deletions test/html-webpack-plugin/expectedOutput-2.0/output.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ Child html-webpack-plugin for "index.html":
Asset Size Chunks Chunk Names
index.html 553 kB 0
chunk {0} index.html 536 kB [rendered]
[0] ./~/html-webpack-plugin/lib/loader.js!./~/html-webpack-plugin/default_index.ejs 550 bytes {0} [built]
[1] ./~/html-webpack-plugin/~/lodash/lodash.js 535 kB {0} [built]
[0] ./~/html-webpack-plugin/lib/loader.js!./~/html-webpack-plugin/default_index.ejs 540 bytes {0} [built]
[1] ./~/lodash/lodash.js 535 kB {0} [built]
[2] (webpack)/buildin/module.js 241 bytes {0} [built]
7 changes: 5 additions & 2 deletions test/issue81/expectedOutput-2.0/bundle.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion test/issue81/expectedOutput-2.0/bundle.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions test/issue81/expectedOutput-2.0/output.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Asset Size Chunks Chunk Names
bundle.js 2.42 kB 0 [emitted] main
bundle.js.map 2.51 kB 0 [emitted] main
chunk {0} bundle.js, bundle.js.map (main) 896 bytes [rendered]
[0] ./.test/issue81/a.ts 896 bytes {0} [built]
bundle.js 2.76 kB 0 [emitted] main
bundle.js.map 1.66 kB 0 [emitted] main
chunk {0} bundle.js, bundle.js.map (main) 1.23 kB [rendered]
[0] ./.test/issue81/a.ts 1.23 kB {0} [built]
2 changes: 1 addition & 1 deletion test/issue81/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ module.exports = {
devtool: 'source-map',
module: {
loaders: [
{ test: /\.ts$/, loader: 'babel-loader!ts-loader' }
{ test: /\.ts$/, loader: 'babel-loader?presets[]=es2015!ts-loader' }
]
}
}
Expand Down
14 changes: 6 additions & 8 deletions test/issue92/expectedOutput-2.0/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,17 @@

'use strict';

Object.defineProperty(exports, '__esModule', {
Object.defineProperty(exports, "__esModule", {
value: true
});

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }
var _submodule = __webpack_require__(1);

var _submoduleSubmodule = __webpack_require__(1);
var _submodule2 = _interopRequireDefault(_submodule);

var _submoduleSubmodule2 = _interopRequireDefault(_submoduleSubmodule);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

exports['default'] = _submoduleSubmodule2['default'];
module.exports = exports['default'];
exports.default = _submodule2.default;

/***/ },
/* 1 */
Expand All @@ -68,8 +67,7 @@
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = "Hello from submodule";
module.exports = exports["default"];
exports.default = "Hello from submodule";

/***/ }
/******/ ]);
8 changes: 4 additions & 4 deletions test/issue92/expectedOutput-2.0/output.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Asset Size Chunks Chunk Names
bundle.js 2.03 kB 0 [emitted] main
chunk {0} bundle.js (main) 565 bytes [rendered]
[0] ./.test/issue92/app.ts 404 bytes {0} [built]
[1] ./.test/issue92/submodule/submodule.tsx 161 bytes {0} [built]
bundle.js 1.91 kB 0 [emitted] main
chunk {0} bundle.js (main) 444 bytes [rendered]
[0] ./.test/issue92/app.ts 323 bytes {0} [built]
[1] ./.test/issue92/submodule/submodule.tsx 121 bytes {0} [built]
2 changes: 1 addition & 1 deletion test/issue92/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ module.exports = {
},
module: {
loaders: [
{ test: /\.tsx?$/, loader: 'babel-loader!ts-loader' }
{ test: /\.tsx?$/, loader: 'babel-loader?presets[]=es2015!ts-loader' }
]
}
}
Expand Down
3 changes: 1 addition & 2 deletions test/jsxPreserve/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
This test demonstrates the new JSX functionality of TypeScript.

Note that the nightly build of TypeScript is required for this functionality to work.
Install `typescript@next` to use. Also note that React is not actually bundled here.
Note that React is not actually bundled here.

This particular test demonstrates the "preserve" capability of TypeScript. In order to be
used with React it needs to be further transformed with Babel (as seen in this example).
Expand Down
7 changes: 4 additions & 3 deletions test/jsxPreserve/expectedOutput-2.0/bundle.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,15 +45,16 @@
/***/ function(module, exports, __webpack_require__) {

"use strict";
var __extends = undefined && undefined.__extends || function (d, b) {

var __extends = this && this.__extends || function (d, b) {
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
function __() {
this.constructor = d;
}
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
};
var React = __webpack_require__(1);
var MyComponent = (function (_super) {
var MyComponent = function (_super) {
__extends(MyComponent, _super);
function MyComponent() {
_super.apply(this, arguments);
Expand All @@ -66,7 +67,7 @@
);
};
return MyComponent;
})(React.Component);
}(React.Component);
React.render(React.createElement(MyComponent, { content: "Hello World" }), document.body);

/***/ },
Expand Down
6 changes: 3 additions & 3 deletions test/jsxPreserve/expectedOutput-2.0/output.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Asset Size Chunks Chunk Names
bundle.js 2.29 kB 0 [emitted] main
chunk {0} bundle.js (main) 819 bytes [rendered]
[0] ./.test/jsxPreserve/app.tsx 777 bytes {0} [built]
bundle.js 2.28 kB 0 [emitted] main
chunk {0} bundle.js (main) 808 bytes [rendered]
[0] ./.test/jsxPreserve/app.tsx 766 bytes {0} [built]
[1] external "react" 42 bytes {0} [not cacheable]
5 changes: 1 addition & 4 deletions test/jsxPreserve/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
{
"compilerOptions": {
"jsx": "preserve"
},
"files": [
"react.d.ts"
]
}
}
2 changes: 1 addition & 1 deletion test/jsxPreserve/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ module.exports = {
},
module: {
loaders: [
{ test: /\.ts(x?)$/, loader: 'babel-loader!ts-loader' }
{ test: /\.ts(x?)$/, loader: 'babel-loader?presets[]=react!ts-loader' }
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion test/run-tests-as-child.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ function runTestAsChildProcess(testName) {
var excludeVersions = versionsHaveBeenReported ? ' --exclude-versions' : '';
var saveOutput = saveOutputMode ? ' --save-output' : '';
versionsHaveBeenReported = true;
var testOutput = execSync('mocha --reporter spec test/run.js --single-test ' + testName + excludeVersions, { stdio: 'inherit' });
var testOutput = execSync('mocha --reporter spec test/run.js --single-test ' + testName + excludeVersions + saveOutput, { stdio: 'inherit' });
passingTests.push(testName);
}
catch (err) {
Expand Down

0 comments on commit 9482255

Please sign in to comment.