Repository navigation
Expand file tree
/
Copy pathpackage.json
More file actions
166 lines (166 loc) · 6.27 KB
/
Copy pathpackage.json
File metadata and controls
166 lines (166 loc) · 6.27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
{
"name": "testdouble",
"version": "4.0.0",
"description": "A minimal test double library for TDD with JavaScript",
"homepage": "https://github.com/testdouble/testdouble.js",
"author": {
"name": "Justin Searls",
"email": "justin@testdouble.com",
"url": "http://testdouble.com"
},
"main": "lib/index.js",
"exports": {
".": {
"types": "./index.d.ts",
"browser": {
"import": "./dist/testdouble.mjs"
},
"require": "./lib/index.js",
"import": "./lib/index.mjs"
},
"./dist/testdouble.js": {
"types": "./index.d.ts",
"default": "./dist/testdouble.js"
},
"./dist/testdouble.mjs": {
"types": "./index.d.ts",
"default": "./dist/testdouble.mjs"
},
"./package.json": "./package.json"
},
"files": [
"src",
"lib",
"dist",
"index.d.ts"
],
"config": {
"build_file": "dist/testdouble.js"
},
"scripts": {
"clean": "rimraf dist lib coverage",
"clean:hard": "npm run clean && rimraf node_modules \"examples/*/node_modules\"",
"postclean": "mkdirp dist",
"compile:browser": "cross-conf-env browserify src/index.js --standalone td --outfile $npm_package_config_build_file -p [ tsify --project tsconfig-browser.json ] -p headerify",
"compile:node": "tsc",
"compile:browser-esm": "node script/build-browser-esm.js",
"compile:esm": "cp src/index.mjs lib/index.mjs",
"precompile": "npm run clean",
"compile": "npm run compile:node && npm run compile:browser && npm run compile:browser-esm && npm run compile:esm",
"cover": "nyc --reporter=lcov --reporter=text-summary --reporter=html npm test",
"style": "npm run style:js && npm run style:ts",
"style:js": "standard --fix",
"style:ts": "standard --fix --parser @typescript-eslint/parser --plugin @typescript-eslint/eslint-plugin \"**/*.ts\"",
"test": "npm run test:unit && npm run test:safe && npm run test:esm && npm run test:esm-auto-loader && npm run test:no-loader-esm && npm run test:example",
"test:unit": "teenytest --helper test/helper.js \"test/unit/**/*.test.{js,ts}\"",
"test:safe": "teenytest --helper test/helper.js \"test/safe/**/*.test.{js,ts}\"",
"test:esm": "cross-env NODE_OPTIONS=\"--loader=quibble\" TS_NODE_IGNORE=\"node_modules,notypescript\" ./test/safe-esm/teenytest-proxy.js --helper test/helper.js test/safe-esm/replace.test.js test/safe-esm/list.test.js",
"test:esm-auto-loader": "node test/support/supports-auto-load.js not || cross-env TS_NODE_IGNORE=\"node_modules,notypescript\" ./test/safe-esm/teenytest-proxy.js --helper test/helper.js test/safe-esm/replace.test.js",
"test:no-loader-esm": "node test/support/supports-auto-load.js || cross-env TS_NODE_IGNORE=\"node_modules,notypescript\" teenytest test/helper.js './test/safe-esm/*.no-loader-test.{mjs,js}'",
"test:ci": "npm run compile && npm run style && npm test && echo \"All done!\"",
"test:example": "npm run test:example:babel && npm run test:example:jest && npm run test:example:jest-broken && npm run test:example:node && npm run test:example:node-ava && npm run test:example:node-esm && npm run test:example:node-esm-pnpm && npm run test:example:webpack && npm run test:example-web-test-runner && npm run test:example-esm-auto-loader",
"test:example-esm-auto-loader": "node test/support/supports-auto-load.js not || npm run test:example:node-esm-auto-loader",
"test:example-web-test-runner": "node test/support/supports-web-test-runner.js not || npm run test:example:web-test-runner",
"test:example:babel": "bash ./script/run-examples babel",
"test:example:jest": "bash ./script/run-examples jest",
"test:example:jest-broken": "bash ./script/run-examples jest-broken",
"test:example:node": "bash ./script/run-examples node",
"test:example:node-ava": "bash ./script/run-examples node-ava",
"test:example:node-esm": "bash ./script/run-examples node-esm",
"test:example:node-esm-pnpm": "bash ./script/run-examples node-esm-pnpm",
"test:example:node-esm-auto-loader": "bash ./script/run-examples node-esm-auto-loader",
"test:example:web-test-runner": "bash ./script/run-examples web-test-runner",
"test:example:webpack": "bash ./script/run-examples webpack",
"version:write": "echo \"export default '$npm_package_version'\" > src/version.js",
"preversion": "git pull --rebase",
"version": "npm run version:write && npm run compile && git add src/version.js",
"postversion": "git push --tags && git push && npm publish",
"prepare": "npm run compile"
},
"browser": {
"./src/replace/module/index.js": "./src/replace/module/index.browser.js",
"./lib/replace/module/index.js": "./lib/replace/module/index.browser.js",
"quibble": "./src/quibble.browser.js"
},
"standard": {
"globals": [
"td",
"assert",
"ES_SUPPORT"
],
"ignore": [
"index.d.ts",
"examples/**"
]
},
"nyc": {
"include": [
"src/**/*.js"
],
"exclude": [
"examples"
],
"all": true
},
"teenytest": {
"plugins": [
"test/support/tdify-plugin.js",
"teenytest-promise"
]
},
"dependencies": {
"lodash": "^4.17.21",
"quibble": "^0.13.0",
"stringify-object-es5": "^2.5.0",
"theredoc": "^1.0.0"
},
"devDependencies": {
"@types/node": "^20.9.0",
"@typescript-eslint/eslint-plugin": "^6.10.0",
"@typescript-eslint/parser": "^6.10.0",
"browserify": "^17.0.0",
"cross-conf-env": "^1.3.0",
"cross-env": "^7.0.3",
"dedent": "^1.5.1",
"headerify": "^1.0.1",
"is-number": "^7.0.0",
"is-promise": "^4.0.0",
"mkdirp": "^3.0.1",
"nyc": "^15.1.0",
"rimraf": "^5.0.5",
"standard": "^17.1.0",
"teenytest": "^6.0.5",
"teenytest-promise": "^1.0.0",
"testdouble": "^3.20.0",
"ts-node": "^10.9.1",
"tsify": "^5.0.4",
"typescript": "^5.2.2"
},
"directories": {
"doc": "./docs",
"example": "./examples",
"lib": "./lib",
"src": "./src"
},
"typings": "./index.d.ts",
"keywords": [
"tdd",
"bdd",
"mock",
"stub",
"spy",
"test double",
"double"
],
"bugs": {
"url": "https://github.com/testdouble/testdouble.js/issues"
},
"repository": {
"type": "git",
"url": "https://github.com/testdouble/testdouble.js.git"
},
"license": "MIT",
"engines": {
"node": ">= 22"
}
}