Skip to content
This repository was archived by the owner on Aug 11, 2025. It is now read-only.

Commit 64cef5e

Browse files
committed
update dependencies
1 parent 6f9fcdc commit 64cef5e

File tree

3 files changed

+65
-61
lines changed

3 files changed

+65
-61
lines changed

gulpfile.js

Lines changed: 50 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -13,17 +13,17 @@ var gulp = require("gulp"),
1313
//******************************************************************************
1414
//* LINT
1515
//******************************************************************************
16-
gulp.task("lint", function() {
16+
gulp.task("lint", function () {
1717

1818
var config = {
1919
fornatter: "verbose",
2020
emitError: (process.env.CI) ? true : false
2121
};
2222

2323
return gulp.src([
24-
"src/**/**.ts",
25-
"test/**/**.test.ts"
26-
])
24+
"src/**/**.ts",
25+
"test/**/**.test.ts"
26+
])
2727
.pipe(tslint(config))
2828
.pipe(tslint.report());
2929
});
@@ -35,12 +35,12 @@ var tsLibProject = tsc.createProject("tsconfig.json", {
3535
module: "commonjs"
3636
});
3737

38-
gulp.task("build-lib", function() {
38+
gulp.task("build-lib", function () {
3939
return gulp.src([
40-
"src/**/*.ts"
41-
])
40+
"src/**/*.ts"
41+
])
4242
.pipe(tsLibProject())
43-
.on("error", function(err) {
43+
.on("error", function (err) {
4444
process.exit(1);
4545
})
4646
.js.pipe(gulp.dest("lib/"));
@@ -50,12 +50,12 @@ var tsAmdProject = tsc.createProject("tsconfig.json", {
5050
module: "amd"
5151
});
5252

53-
gulp.task("build-amd", function() {
53+
gulp.task("build-amd", function () {
5454
return gulp.src([
55-
"src/**/*.ts"
56-
])
55+
"src/**/*.ts"
56+
])
5757
.pipe(tsAmdProject())
58-
.on("error", function(err) {
58+
.on("error", function (err) {
5959
process.exit(1);
6060
})
6161
.js.pipe(gulp.dest("amd/"));
@@ -66,12 +66,12 @@ var tsEsProject = tsc.createProject("tsconfig.json", {
6666
module: "es2015"
6767
});
6868

69-
gulp.task("build-es", function() {
69+
gulp.task("build-es", function () {
7070
return gulp.src([
71-
"src/**/*.ts"
72-
])
71+
"src/**/*.ts"
72+
])
7373
.pipe(tsEsProject())
74-
.on("error", function(err) {
74+
.on("error", function (err) {
7575
process.exit(1);
7676
})
7777
.js.pipe(gulp.dest("es/"));
@@ -82,12 +82,12 @@ var tsDtsProject = tsc.createProject("tsconfig.json", {
8282
noResolve: false
8383
});
8484

85-
gulp.task("build-dts", function() {
85+
gulp.task("build-dts", function () {
8686
return gulp.src([
87-
"src/**/*.ts"
88-
])
87+
"src/**/*.ts"
88+
])
8989
.pipe(tsDtsProject())
90-
.on("error", function(err) {
90+
.on("error", function (err) {
9191
process.exit(1);
9292
})
9393
.dts.pipe(gulp.dest("dts"));
@@ -99,66 +99,69 @@ gulp.task("build-dts", function() {
9999
//******************************************************************************
100100
var tstProject = tsc.createProject("tsconfig.json");
101101

102-
gulp.task("build-src", function() {
102+
gulp.task("build-src", function () {
103103
return gulp.src([
104-
"src/**/*.ts"
105-
])
104+
"src/**/*.ts"
105+
])
106106
.pipe(tstProject())
107-
.on("error", function(err) {
107+
.on("error", function (err) {
108108
process.exit(1);
109109
})
110110
.js.pipe(gulp.dest("src/"));
111111
});
112112

113113
var tsTestProject = tsc.createProject("tsconfig.json", { rootDir: "./" });
114114

115-
gulp.task("build-test", function() {
115+
gulp.task("build-test", function () {
116116
return gulp.src([
117-
"test/**/*.ts"
118-
])
117+
"test/**/*.ts"
118+
])
119119
.pipe(tsTestProject())
120-
.on("error", function(err) {
120+
.on("error", function (err) {
121121
process.exit(1);
122122
})
123123
.js.pipe(gulp.dest("./test/"));
124124
});
125125

126-
gulp.task("mocha", function() {
126+
gulp.task("mocha", function () {
127127
return gulp.src([
128-
"node_modules/reflect-metadata/Reflect.js",
129-
"test/**/*.test.js"
130-
])
128+
"node_modules/reflect-metadata/Reflect.js",
129+
"test/**/*.test.js"
130+
])
131131
.pipe(mocha({
132132
ui: "bdd"
133133
}))
134134
.pipe(istanbul.writeReports());
135135
});
136136

137-
gulp.task("istanbul:hook", function() {
137+
gulp.task("istanbul:hook", function () {
138138
return gulp.src(["src/**/*.js"])
139139
// Covering files
140140
.pipe(istanbul())
141141
// Force `require` to return covered files
142142
.pipe(istanbul.hookRequire());
143143
});
144144

145-
gulp.task("test", function(cb) {
146-
runSequence("istanbul:hook", "mocha", cb);
147-
});
145+
gulp.task("test", gulp.series("istanbul:hook", "mocha"));
148146

149-
gulp.task("build", function(cb) {
150-
runSequence(
151-
"lint", ["build-src", "build-es", "build-lib", "build-amd", "build-dts"], // tests + build es and lib
147+
gulp.task("build",
148+
gulp.series(
149+
"lint",
150+
gulp.parallel(
151+
"build-src",
152+
"build-es",
153+
"build-lib",
154+
"build-amd",
155+
"build-dts"
156+
),
152157
"build-test",
153-
cb);
154-
});
158+
)
159+
);
155160

156161
//******************************************************************************
157162
//* DEFAULT
158163
//******************************************************************************
159-
gulp.task("default", function(cb) {
160-
runSequence(
161-
"build",
162-
"test",
163-
cb);
164-
});
164+
gulp.task("default", gulp.series(
165+
"build",
166+
"test",
167+
));

package.json

Lines changed: 14 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -25,22 +25,23 @@
2525
"homepage": "https://github.com/inversify/inversify-binding-decorators#readme",
2626
"dependencies": {},
2727
"devDependencies": {
28-
"@types/chai": "4.1.4",
29-
"@types/mocha": "5.2.6",
30-
"@types/sinon": "7.0.5",
31-
"chai": "4.1.2",
32-
"gulp": "3.9.1",
28+
"@types/chai": "4.2.0",
29+
"@types/mocha": "5.2.7",
30+
"@types/sinon": "7.0.13",
31+
"chai": "4.2.0",
32+
"gulp": "4.0.2",
3333
"gulp-istanbul": "1.1.3",
34-
"gulp-mocha": "6.0.0",
35-
"gulp-tslint": "8.1.3",
34+
"gulp-mocha": "7.0.1",
35+
"gulp-tslint": "8.1.4",
3636
"gulp-typescript": "5.0.1",
3737
"inversify": "5.0.1",
38-
"mocha": "5.2.0",
39-
"publish-please": "5.4.3",
38+
"mocha": "6.2.0",
39+
"publish-please": "5.5.1",
4040
"reflect-metadata": "0.1.13",
4141
"run-sequence": "2.2.1",
42-
"sinon": "7.2.3",
43-
"tslint": "5.9.1",
44-
"typescript": "2.9.1"
42+
"sinon": "7.4.1",
43+
"tslint": "5.19.0",
44+
"typescript": "3.5.3",
45+
"updates": "^8.5.3"
4546
}
46-
}
47+
}

test/decorator/provide.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ describe("provide", () => {
2929
class Ninja { }
3030
provide("Ninja")(Ninja);
3131
const bindingSpy = sandbox.spy();
32-
const bindSpy = sandbox.spy(() => { return { to: bindingSpy }; });
32+
const bindSpy: any = sandbox.spy(() => { return { to: bindingSpy }; });
3333

3434
let bindingMetadata: interfaces.ProvideSyntax = Reflect.getMetadata(METADATA_KEY.provide, Reflect)[0];
3535
bindingMetadata.constraint(bindSpy, Ninja);

0 commit comments

Comments
 (0)