Skip to content

Commit

Permalink
fix: make all tests pass on every TypeScript version in the range [3.…
Browse files Browse the repository at this point in the history
…0, 4.3-rc1]
  • Loading branch information
wessberg committed May 21, 2021
1 parent 20e0ca4 commit 265ac93
Show file tree
Hide file tree
Showing 37 changed files with 7,806 additions and 5,203 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
strategy:
matrix:
os: [windows-latest, macos-latest, ubuntu-18.04]
node: [10, 13]
node: [12, 14, 15]

steps:
- name: Checkout code
Expand Down
1 change: 1 addition & 0 deletions .husky/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
_
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

pretty-quick --staged
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ For example, an expression such as:
```typescript
import { DIContainer } from "@wessberg/di";
import { MyInterface } from "./my-interface";
import { Myimplementation } from "./my-implementation";
import { MyImplementation } from "./my-implementation";

const container = new DIContainer();
container.registerSingleton<MyInterface, MyImplementation>();
Expand Down
90 changes: 50 additions & 40 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@
"version": "2.1.1",
"description": "A Custom Transformer for Typescript that enables compile-time Dependency Injection",
"scripts": {
"generate:scaffold": "scaffold all --yes",
"generate:sandhog": "sandhog all --yes",
"generate:changelog": "standard-changelog --first-release",
"generate:all": "pnpm run generate:scaffold && pnpm run generate:changelog",
"clean:dist": "rimraf dist",
"clean": "pnpm run clean:dist",
"generate:all": "pnpm run generate:sandhog && pnpm run generate:changelog",
"clean": "rimraf dist",
"lint": "tsc --noEmit && eslint \"src/**/*.ts\" --color",
"prettier": "prettier --write '{src,test,documentation}/**/*.{js,ts,json,html,xml,css,md}'",
"prettier": "prettier --write \"{src,test,documentation}/**/*.{js,ts,json,html,xml,css,md}\"",
"test": "ava",
"prebuild": "pnpm run clean:dist",
"prebuild": "pnpm run clean",
"build": "pnpm run rollup",
"prewatch": "pnpm run clean:dist",
"watch": "pnpm run rollup -- --watch",
"rollup": "rollup -c rollup.config.js",
"preversion": "pnpm run lint && NODE_ENV=production pnpm run build",
"preversion": "pnpm run lint && pnpm run build",
"version": "pnpm run generate:all && git add .",
"release": "np --no-cleanup --no-yarn"
"release": "np --no-cleanup --no-yarn --no-tests",
"update:check": "pnpx npm-check-updates -x np,slash --dep dev,prod",
"update:commit": "pnpx npm-check-updates -u -x np,slash --dep dev,prod && pnpm update && pnpm install"
},
"keywords": [
"DI",
Expand Down Expand Up @@ -50,37 +50,52 @@
],
"license": "MIT",
"devDependencies": {
"@types/prettier": "^2.0.1",
"@types/node": "^14.0.5",
"@typescript-eslint/eslint-plugin": "^3.0.1",
"@typescript-eslint/parser": "^3.0.1",
"@wessberg/rollup-plugin-ts": "^1.2.24",
"@wessberg/scaffold": "^1.0.29",
"@types/node": "^15.3.1",
"@types/prettier": "^2.2.3",
"@types/semver": "^7.3.6",
"@typescript-eslint/eslint-plugin": "^4.24.0",
"@typescript-eslint/parser": "^4.24.0",
"@wessberg/di": "^2.0.3",
"@wessberg/ts-config": "^1.0.12",
"ava": "^3.8.2",
"eslint": "^7.1.0",
"slash": "^3.0.0",
"eslint-config-prettier": "^6.11.0",
"eslint-plugin-import": "^2.20.2",
"eslint-plugin-jsdoc": "^25.4.2",
"husky": "^4.2.5",
"np": "^6.2.3",
"pnpm": "^4.14.4",
"prettier": "^2.0.5",
"pretty-quick": "^2.0.1",
"@wessberg/rollup-plugin-ts": "^1.3.14",
"@wessberg/ts-config": "^1.1.0",
"semver": "^7.3.5",
"ava": "^3.15.0",
"eslint": "^7.26.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-import": "^2.23.2",
"eslint-plugin-jsdoc": "^34.8.2",
"husky": "^6.0.0",
"np": "^6.5.0",
"pnpm": "^6.4.0",
"prettier": "^2.3.0",
"pretty-quick": "^3.1.0",
"rimraf": "^3.0.2",
"rollup": "^2.10.9",
"standard-changelog": "^2.0.24",
"ts-node": "^8.10.1",
"typescript": "^3.9.3"
"rollup": "^2.48.0",
"sandhog": "^1.0.38",
"slash": "^3.0.0",
"standard-changelog": "^2.0.27",
"ts-node": "^9.1.1",
"typescript": "^4.3.1-rc",
"typescript-3-0-1": "npm:typescript@3.0.1",
"typescript-3-1-1": "npm:typescript@3.1.1",
"typescript-3-2-1": "npm:typescript@3.2.1",
"typescript-3-3-1": "npm:typescript@3.3.1",
"typescript-3-4-1": "npm:typescript@3.4.1",
"typescript-3-5-1": "npm:typescript@3.5.1",
"typescript-3-6-2": "npm:typescript@3.6.2",
"typescript-3-7-2": "npm:typescript@3.7.2",
"typescript-3-8-3": "npm:typescript@3.8.3",
"typescript-3-9-2": "npm:typescript@3.9.2",
"typescript-4-0-3": "npm:typescript@4.0.3",
"typescript-4-1-2": "npm:typescript@4.1.2",
"typescript-4-2-4": "npm:typescript@4.2.4"
},
"dependencies": {
"@wessberg/ts-evaluator": "^0.0.25",
"tslib": "^2.0.0"
"ts-evaluator": "^0.1.0",
"tslib": "^2.2.0"
},
"peerDependencies": {
"typescript": "^3.x"
"typescript": ">=3.x || >= 4.x"
},
"repository": {
"type": "git",
Expand All @@ -98,14 +113,9 @@
"engines": {
"node": ">=8.0.0"
},
"husky": {
"hooks": {
"pre-commit": "pretty-quick --staged"
}
},
"ava": {
"files": [
"test/**.test.ts"
"test/**/**.test.ts"
],
"verbose": true,
"timeout": "40s",
Expand Down
Loading

0 comments on commit 265ac93

Please sign in to comment.