continue-custom/extensions/vscode/e2e
Dallin Romney 580fc938de
Merge pull request #6711 from fbricon/empty-selection-selects-line
feat: allow Cmd+L / Cmd+I on empty selection to select the entire file
2025-09-10 18:49:06 -07:00
..
actions fix: iterations on notch updates - create agent vs assistant, skip gui tests for now 2025-09-09 20:27:50 -07:00
selectors fix: iterations on notch updates - create agent vs assistant, skip gui tests for now 2025-09-09 20:27:50 -07:00
test-continue remove builtin_ from tool names, add tool policy migration 2025-07-01 23:52:24 -07:00
test-continue-yaml remove builtin_ from tool names, add tool policy migration 2025-07-01 23:52:24 -07:00
tests Merge pull request #6711 from fbricon/empty-selection-selects-line 2025-09-10 18:49:06 -07:00
constants.ts feat: add XXLP 2025-07-23 10:40:39 -07:00
get-latest-vsix.sh improv: copy vsix 2024-12-04 16:55:36 -08:00
README.md feat: compaction (#6662) 2025-07-17 16:22:46 -07:00
TestUtils.ts feat: compaction (#6662) 2025-07-17 16:22:46 -07:00

E2E Tests

Setup

When running e2e tests for the first time

npm run e2e:all

Run

Depending on what code you update, you can use a faster loop to test your changes:

  • If you update the e2e test code and/or config.yaml/json, you can run npm run e2e:quick
  • If you update the extension code, you can run npm run e2e:recompile
  • If you update the gui code, you can run npm run e2e:rebuild-gui

Writing tests

All e2e tests are separated (by folder) into

  • selectors - functions that return elements
  • actions - functions that perform actions on the editor
  • tests - the actual tests, which are typically longer paths of functionality rather than individual actions

Why are my tests failing?

  • Did you place a data-testid on a React component instead of an actual HTML element?
  • Do you have a config.yaml locally but the test is failing when running with config.json in CI?
  • Is your data-testid or selector actually just wrong?
  • Are you inconsistently getting different behaviors? You can try adding a TestUtils.waitForTimeout between two events if you think it's caused by a race condition. Note that this may lead to flake down the road.
  • Alternatively, you can add a TestUtils.waitForSuccess

How is it connecting to the LLM?

  • This depends on the model provider written inside the test-continue/config.json and test-continue/config.yaml. If the model provider is mock, it will use MockLLM, and if it uses test, it will use TestLLM.

Quirks

  • For non-macOS systems, codesign is not available. You should run npm run e2e:all-non-mac instead of npm run e2e:all.