trisquel-icecat/icecat/devtools/docs/contributor/tests
2025-07-17 09:32:21 -06:00
..
debugging-intermittents.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
mochitest-chrome.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
mochitest-devtools.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
node-tests.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-compare-link.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-compare.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-create-gecko-profile.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-damp.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-filter-subtests.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
perfherder-subtests.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
performance-tests-damp.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
performance-tests-overview.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
README.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
regression-graph.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
regression-popup.png icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
writing-perf-tests-example.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
writing-perf-tests-tips.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
writing-perf-tests.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
writing-tests.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00
xpcshell.md icecat: initial release for Trisquel 12.0, Ecne 2025-07-17 09:32:21 -06:00

Automated tests

When working on a patch for DevTools, there's almost never a reason not to add a new test. If you are fixing a bug, you probably should write a new test to prevent this bug from occurring again. If you're implementing a new feature, you should write new tests to cover the aspects of this new feature.

Ask yourself:

  • Are there enough tests for my patch?
  • Are they the right types of tests?

We use three suites of tests:

  • xpcshell: Unit-test style of tests. No browser window, only a JavaScript shell. Mostly testing APIs directly.
  • Chrome mochitests: Unit-test style of tests, but with a browser window. Mostly testing APIs that interact with the DOM.
  • DevTools mochitests: Integration style of tests. Fires up a whole browser window with every test and you can test clicking on buttons, etc.

To run all DevTools tests, regardless of suite type:

./mach test devtools/*

Have a look at the child pages for more specific commands for running only a single suite or single test in a suite.