summaryrefslogtreecommitdiffstats
path: root/pkg
diff options
context:
space:
mode:
authorJesse Duffield <jessedduffield@gmail.com>2022-11-13 11:54:37 +1100
committerGitHub <noreply@github.com>2022-11-13 11:54:37 +1100
commitfbac05fff74f7780c99e6c9f9d583c9786a447fc (patch)
tree6ec4a77664304b498cbe5d1f18e740ce9d7d924b /pkg
parent99e05ee13830aaffcaa1c0bee9fe5c4112703285 (diff)
Update README.md
Diffstat (limited to 'pkg')
-rw-r--r--pkg/integration/README.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/pkg/integration/README.md b/pkg/integration/README.md
index debc9ced4..bb22efab5 100644
--- a/pkg/integration/README.md
+++ b/pkg/integration/README.md
@@ -61,6 +61,15 @@ The name of a test is based on its path, so the name of the test at `pkg/integra
You can pass the KEY_PRESS_DELAY env var to the test runner in order to set a delay in milliseconds between keypresses, which helps for watching a test at a realistic speed to understand what it's doing. Or you can pass the '--slow' flag which sets a pre-set 'slow' key delay. In the tui you can press 't' to run the test in slow mode.
+### Running tests in VSCode
+
+If you've opened an integration test file in your editor you can run that file by bringing up the command panel with `cmd+shift+p` and typing 'run task', then selecting the test task you want to run
+
+![image](https://user-images.githubusercontent.com/8456633/201500427-b86e129f-5f35-4d55-b7bd-fff5d8e4a04e.png)
+![image](https://user-images.githubusercontent.com/8456633/201500431-903deb8c-c210-4054-8514-ab7088c7a839.png)
+The test will run in a VSCode terminal:
+![image](https://user-images.githubusercontent.com/8456633/201500446-b87abf11-9653-438f-8a9a-e0bf8abdb7ee.png)
+
### Snapshots
At the moment (this is subject to change) each test has a snapshot repo created after running for the first time. These snapshots live in `test/integration_new`, in folders named 'expected' (alongside the 'actual' folders which contain the resulting repo from the last test run). Whenever you run a test, the resultant repo will be compared against the snapshot repo and if they're different, you'll be asked whether you want to update the snapshot. If you want to update a snapshot without being prompted you can pass MODE=update to the test runner.