You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -97,12 +97,12 @@ We have several types of tests:
97
97
98
98
* Unit tests: these live in the `tests/pure-tests/` directory
99
99
* View tests: these live in `src/view/variant-analysis/__tests__/`
100
-
* VSCode integration tests: these live in `src/vscode-tests/no-workspace` and `src/vscode-tests/minimal-workspace`
101
-
* CLI integration tests: these live in `src/vscode-tests/cli-integration`
100
+
* VSCode integration tests: these live in `test/vscode-tests/no-workspace` and `test/vscode-tests/minimal-workspace`
101
+
* CLI integration tests: these live in `test/vscode-tests/cli-integration`
102
102
103
103
The CLI integration tests require an instance of the CodeQL CLI to run so they will require some extra setup steps. When adding new tests to our test suite, please be mindful of whether they need to be in the cli-integration folder. If the tests don't depend on the CLI, they are better suited to being a VSCode integration test.
104
104
105
-
Any test data you're using (sample projects, config files, etc.) must go in a `src/vscode-tests/*/data` directory. When you run the tests, the test runner will copy the data directory to `out/vscode-tests/*/data`.
105
+
Any test data you're using (sample projects, config files, etc.) must go in a `test/vscode-tests/*/data` directory. When you run the tests, the test runner will copy the data directory to `out/vscode-tests/*/data`.
106
106
107
107
#### Running the tests
108
108
@@ -155,16 +155,16 @@ The CLI integration tests require the CodeQL standard libraries in order to run
155
155
##### 1. From the terminal
156
156
157
157
The easiest way to run a single test is to change the `it` of the test to `it.only` and then run the test command with some additional options
158
-
to only run tests for this specific file. For example, to run the test `src/vscode-tests/cli-integration/run-queries.test.ts`:
158
+
to only run tests for this specific file. For example, to run the test `test/vscode-tests/cli-integration/run-queries.test.ts`:
159
159
160
160
```shell
161
-
npm run cli-integration -- --runTestsByPath src/vscode-tests/cli-integration/run-queries.test.ts
161
+
npm run cli-integration -- --runTestsByPath test/vscode-tests/cli-integration/run-queries.test.ts
162
162
```
163
163
164
-
You can also use the `--testNamePattern` option to run a specific test within a file. For example, to run the test `src/vscode-tests/cli-integration/run-queries.test.ts`:
164
+
You can also use the `--testNamePattern` option to run a specific test within a file. For example, to run the test `test/vscode-tests/cli-integration/run-queries.test.ts`:
165
165
166
166
```shell
167
-
npm run cli-integration -- --runTestsByPath src/vscode-tests/cli-integration/run-queries.test.ts --testNamePattern "should create a QueryEvaluationInfo"
167
+
npm run cli-integration -- --runTestsByPath test/vscode-tests/cli-integration/run-queries.test.ts --testNamePattern "should create a QueryEvaluationInfo"
0 commit comments