Fix(doc) - Add section in docs for deflaking (#10750)

Co-authored-by: gemini-cli-robot <gemini-cli-robot@google.com>
This commit is contained in:
shishu314
2025-10-08 17:21:02 -04:00
committed by GitHub
parent 3d106186f4
commit 8d8a2ab64e
2 changed files with 9 additions and 1 deletions

View File

@@ -34,6 +34,14 @@ To run a single test by its name, use the `--test-name-pattern` flag:
npm run test:e2e -- --test-name-pattern "reads a file" npm run test:e2e -- --test-name-pattern "reads a file"
``` ```
### Deflaking a test
Before adding a **new** integration test, you should test it at least 5 times with the deflake script to make sure that it is not flaky.
```bash
npm run deflake -- --runs=5 --command="npm run test:e2e -- --test-name-pattern '<your-new-test-name>'"
```
### Running all tests ### Running all tests
To run the entire suite of integration tests, use the following command: To run the entire suite of integration tests, use the following command:

View File

@@ -57,7 +57,7 @@ async function main() {
}) })
.option('runs', { .option('runs', {
type: 'number', type: 'number',
default: 50, default: 5,
description: 'The number of runs to perform', description: 'The number of runs to perform',
}).argv; }).argv;