mirror of https://github.com/webpack/webpack.git
refactor: use es6 arrow functions for the sake of consistency
This commit is contained in:
parent
dc4320f728
commit
6a6db2a155
|
|
@ -54,7 +54,7 @@ describe("MultiCompiler", function () {
|
|||
});
|
||||
});
|
||||
|
||||
it("should not be running twice at a time (run)", function (done) {
|
||||
it("should not be running twice at a time (run)", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
compiler.run((err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -63,7 +63,7 @@ describe("MultiCompiler", function () {
|
|||
if (err) return done();
|
||||
});
|
||||
});
|
||||
it("should not be running twice at a time (watch)", function (done) {
|
||||
it("should not be running twice at a time (watch)", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
const watcher = compiler.watch({}, (err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -72,7 +72,7 @@ describe("MultiCompiler", function () {
|
|||
if (err) return watcher.close(done);
|
||||
});
|
||||
});
|
||||
it("should not be running twice at a time (run - watch)", function (done) {
|
||||
it("should not be running twice at a time (run - watch)", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
compiler.run((err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -81,7 +81,7 @@ describe("MultiCompiler", function () {
|
|||
if (err) return done();
|
||||
});
|
||||
});
|
||||
it("should not be running twice at a time (watch - run)", function (done) {
|
||||
it("should not be running twice at a time (watch - run)", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
let watcher;
|
||||
watcher = compiler.watch({}, (err, stats) => {
|
||||
|
|
@ -91,7 +91,7 @@ describe("MultiCompiler", function () {
|
|||
if (err) return watcher.close(done);
|
||||
});
|
||||
});
|
||||
it("should not be running twice at a time (instance cb)", function (done) {
|
||||
it("should not be running twice at a time (instance cb)", done => {
|
||||
const compiler = webpack(
|
||||
{
|
||||
context: __dirname,
|
||||
|
|
@ -109,7 +109,7 @@ describe("MultiCompiler", function () {
|
|||
if (err) return done();
|
||||
});
|
||||
});
|
||||
it("should run again correctly after first compilation", function (done) {
|
||||
it("should run again correctly after first compilation", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
compiler.run((err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -120,7 +120,7 @@ describe("MultiCompiler", function () {
|
|||
});
|
||||
});
|
||||
});
|
||||
it("should watch again correctly after first compilation", function (done) {
|
||||
it("should watch again correctly after first compilation", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
compiler.run((err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -132,7 +132,7 @@ describe("MultiCompiler", function () {
|
|||
});
|
||||
});
|
||||
});
|
||||
it("should run again correctly after first closed watch", function (done) {
|
||||
it("should run again correctly after first closed watch", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
const watching = compiler.watch({}, (err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
@ -144,7 +144,7 @@ describe("MultiCompiler", function () {
|
|||
});
|
||||
});
|
||||
});
|
||||
it("should watch again correctly after first closed watch", function (done) {
|
||||
it("should watch again correctly after first closed watch", done => {
|
||||
const compiler = createMultiCompiler();
|
||||
const watching = compiler.watch({}, (err, stats) => {
|
||||
if (err) return done(err);
|
||||
|
|
|
|||
Loading…
Reference in New Issue