-
Notifications
You must be signed in to change notification settings - Fork 2
/
package.json
208 lines (208 loc) · 8.45 KB
/
package.json
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
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
{
"name": "vscode-php-tdd",
"displayName": "PHP TDD",
"description": "Visual Studio Code extension to assist with PHP unit test integration",
"version": "0.0.8",
"publisher": "jasonterando",
"homepage": "https://github.com/jasonterando/vscode-php-tdd",
"repository": {
"type": "git",
"url": "https://github.com/jasonterando/vscode-php-tdd.git"
},
"engines": {
"vscode": "^1.23.0"
},
"categories": [
"Other"
],
"icon": "php-tdd.png",
"activationEvents": [
"onLanguage:php",
"onCommand:phptdd.runUnitTest",
"onCommand:phptdd.runAllUnitTests",
"onCommand:phptdd.runAllWithCoverageUnitTests",
"onCommand:phptdd.initializeUnitTestProject",
"onCommand:phptdd.editUnitTest",
"onCommand:phptdd.clearProblems"
],
"main": "./out/extension",
"contributes": {
"keybindings": [
{
"command": "phptdd.runUnitTest",
"key": "ctrl+alt+t"
}
],
"commands": [
{
"command": "phptdd.initializeUnitTestProject",
"title": "PHP TDD: Initialize PHP Unit Test Project"
},
{
"command": "phptdd.editUnitTest",
"title": "PHP TDD: Edit PHP Unit Test"
},
{
"command": "phptdd.editLastUnitTest",
"title": "PHP TDD: Edit Last PHP Unit Test"
},
{
"command": "phptdd.runUnitTest",
"title": "PHP TDD: Run PHP Unit Test"
},
{
"command": "phptdd.runAllUnitTests",
"title": "PHP TDD: Run PHP All Unit Tests"
},
{
"command": "phptdd.runAllWithCoverageUnitTests",
"title": "PHP TDD: Run PHP All Unit Tests With Coverage"
},
{
"command": "phptdd.clearProblems",
"title": "PHP TDD: Clear All Unit Test Warnings & Errors"
}
],
"configuration": {
"type": "object",
"title": "PHP TDD configuration",
"properties": {
"php-tdd.testSubdirectory": {
"type": "string",
"default": "tests/unit",
"description": "Relative directory within workspace to store unit tests"
},
"php-tdd.testClassTemplateFile": {
"type": "string",
"default": "templates/PHPUnitTestCase.php",
"description": "If set, file (relative path in the workspace) to use as the test class template"
},
"php-tdd.enableAutoRun": {
"type": "boolean",
"default": false,
"description": "If true, unit tests are run automatically as text is edited"
},
"php-tdd.enablePHPExtensions": {
"type": "boolean",
"default": false,
"description": "If true, required JSON and tokenizer PHP modules are explicitly enabled (required if PHP is compiled without them embedded)"
},
"php-tdd.commands.directory": {
"type": "string",
"default": "__WORKSPACE_DIRECTORY__",
"description": "The directory unit test commands are run from"
},
"php-tdd.commands.runUnitTest": {
"type": "string",
"default": "./vendor/bin/phpunit --testdox -c __TEST_SUBDIRECTORY__/phpunit.xml --filter __FUNCTION__ __TEST_SUBDIRECTORY__",
"description": "The command to launch PHPUnit and run an individual unit test"
},
"php-tdd.commands.runAllUnitTests": {
"type": "string",
"default": "./vendor/bin/phpunit --testdox -c __TEST_SUBDIRECTORY__/phpunit.xml __TEST_SUBDIRECTORY__",
"description": "The command to launch PHPUnit to run all unit tests"
},
"php-tdd.commands.runCodeCoverage": {
"type": "string",
"default": "./vendor/bin/phpunit --testdox -c __TEST_SUBDIRECTORY__/phpunit.coverage.xml __TEST_SUBDIRECTORY__",
"description": "The command to launch PHPUnit to run all unit tests and generate code coverage"
},
"php-tdd.commands.codeCoverageReport": {
"type": "string",
"default": "./__TEST_SUBDIRECTORY__/coverage/index.html",
"description": "If set, this file will be displayed after running the code coverage command"
},
"php-tdd.composer.enableInstall": {
"type": "boolean",
"default": true,
"description": "If true, for a new project, Composer and PHPUnit will be added to composer.json"
},
"php-tdd.composer.enableNamespace": {
"type": "boolean",
"default": true,
"description": "If true, when a unit test is added to a class, its namespace will be added to composer.json"
},
"php-tdd.composer.packagesRequired": {
"type": "array",
"default": [
"composer/composer"
],
"description": "If composer.install is true, the composer packages installed during project setup"
},
"php-tdd.composer.packagesDevelopment": {
"type": "array",
"default": [
"phpunit/phpunit:^7.1.5"
],
"description": "If composer.install is true, the composer packages installed during project setup"
},
"php-tdd.composer.commands.directory": {
"type": "string",
"default": "__WORKSPACE_DIRECTORY__",
"description": "The directory composer commands are run from"
},
"php-tdd.composer.commands.require": {
"type": "string",
"default": "composer require __FLAGS__ __PACKAGE__",
"description": "The command used to execute a composer require"
},
"php-tdd.composer.commands.update": {
"type": "string",
"default": "composer update",
"description": "The command used to execute a composer update"
},
"php-tdd.composer.commands.dumpAutoload": {
"type": "string",
"default": "composer dump-autoload",
"description": "The command used to execute a composer dump-autoload"
}
}
}
},
"nyc": {
"extension": [
".ts",
".tsx"
],
"reporter": [
"html"
],
"include": [
"src/**/*.ts"
],
"exclude": [
"src/extension.ts",
"src/test",
"out/test"
],
"all": true,
"produce-source-map": true
},
"devDependencies": {
"@types/glob": "^7.1.3",
"@types/mocha": "^8.0.1",
"@types/minimatch": "^5.1.2",
"@types/node": "^14.14.37",
"@types/sinon": "^9.0.11",
"@types/vscode": "^1.23.0",
"glob": "^7.1.6",
"mocha": "^10.2.0",
"nyc": "^15.1.0",
"sinon": "^10.0.0",
"source-map-support": "^0.5.19",
"ts-node": "^9.1.1",
"tsconfig-paths": "^3.9.0",
"tslint": "^5.20.1",
"typescript": "^4.9.4",
"vscode-uri": "^1.0.8",
"@vscode/test-electron": "^2.2.1"
},
"scripts": {
"vscode:prepublish": "npm run compile",
"compile": "tsc -p ./ && cp src/dump.php out/dump.php && cp -r src/templates out && cp src/test/sample.php out/test/sample.php",
"watch": "tsc -watch -p ./",
"test": "npm run compile && node out/test/runTest.js",
"unit-test": "mocha --require ts-node/register -u tdd --colors src/test/suite/**/*.test.ts",
"coverage": "nyc mocha --require ts-node/register -u tdd --colors src/test/suite/**/*.test.ts"
}
}