~/talk

Testing extensions for Visual Studio Code

Talkat DevConf.CZ 2021 · 2021-02-18..02-20· [testing, developer-experience]
slides:none on file

Testing VS Code extensions proves brittle because UI state and external services matter and unit tests only cover tiny logic bits while workflows break. The Open Build Service Connector uses unit tests with vscode-tests for pure logic, vscode-extension-tester (Selenium/Electron) plus Mocha for integration workflows, and LD_PRELOAD to inject a fake libsecret and fake git for CI. Integration tests run slow, flake under CI, and cannot produce coverage so prioritize the top 20% workflows that cover 80% impact.

AI-written summary · about

  1. 0:00Intro
  2. 3:17Testing Extensions Why is it hard?
  3. 6:42External Services
  4. 8:17Unit testing
  5. 9:30Getting started
  6. 11:05Extension Settings
  7. 13:27Disposables
  8. 15:29Manual testing
  9. 18:33What to test? . check your main workflows
  10. 19:15How to test? • upstream using mocha
  11. 20:26Catches
  12. 22:01Questions?
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.