Skip to content

Commit

Permalink
Docs: Avoid undefined "HTML Runner" term
Browse files Browse the repository at this point in the history
This was never a concrete thing, but was used to refer to what QUnit
does in browser environments. We now call it that, or in some cases,
the "Browser Runner" page.
  • Loading branch information
Krinkle committed Jul 24, 2024
1 parent 948f31e commit d034b2a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion docs/api/QUnit/start.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ version_added: "1.0.0"

Call this method to start the test runner. This indicates that all relevant source code has been loaded and all tests have been defined.

In most environments this is **automatically called** and you do not need to call it. This includes testing via the HTML Runner and the QUnit CLI.
In most environments this is **automatically called** and you do not need to call it. This includes testing in a browser environment, and the QUnit CLI.

If you build a custom test runner (such in SpiderMonkey or Node.js), or if you disable `QUnit.config.autostart` and load test files asynchronously (with AMD, RequireJS, or ESM dynamic imports), then you need to call this once after your test files have been loaded.

Expand Down
8 changes: 4 additions & 4 deletions docs/api/config/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ Configurations are read in the following order:
1. Default values
2. Flat preconfig
3. Object preconfig
4. Runner options (URL parameters in the HTML Reporter, or CLI options in the QUnit CLI)
4. Runner options (URL parameters in a browser, or CLI options in the QUnit CLI)
5. Set `QUnit.config` from your own inline or bootstrap script.

## Set configuration

You can configure the test run via the `QUnit.config` object. In the HTML Runner, you can set the configuration from any script after qunit.js:
You can configure the test run via the `QUnit.config` object. For browser environments, you can configure QUnit from any script after qunit.js:

```html
<!DOCTYPE html>
Expand All @@ -47,7 +47,7 @@ You can configure the test run via the `QUnit.config` object. In the HTML Runner
</body>
```

If you have custom plugins or want to re-use your configuration across multiple HTML test suites, you can also configure your project from an external `/test/bootstrap.js` script. Make sure to place this script before your other test files.
If you have custom plugins or want to re-use your configuration across multiple HTML files, you can also configure your project from an external `/test/bootstrap.js` script. Make sure to place this script before your other test files.

When using the [QUnit CLI](../../cli.md), you can setup your project and configure QUnit via [`--require`](../../cli.md#--require).

Expand Down Expand Up @@ -77,7 +77,7 @@ Preconfig allows integrations to declare configuration without needing to embed,

Flat preconfig allows multiple integrations to seemlessly collaborate, without the risk of projects accidentally unsetting an override (as is the case with Object preconfig).

In the browser context (HTML Runner), global variables that start with `qunit_config_` may override the default value of a configuration option. The following inline script (before loading QUnit), is equivalent to setting `QUnit.config.hidepassed = true; QUnit.config.seed = 'd84af39036'; QUnit.config.testTimeout = 1000;`
In browser environments, global variables that start with `qunit_config_` may override the default value of a configuration option. The following inline script (before loading QUnit), is equivalent to setting `QUnit.config.hidepassed = true; QUnit.config.seed = 'd84af39036'; QUnit.config.testTimeout = 1000;`

```html
<script>
Expand Down
4 changes: 2 additions & 2 deletions docs/api/extension/QUnit.onUncaughtException.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ This method can be safely called at any time, including between or outside tests

In general, you should not use this method and instead throw an error. QUnit automatically finds and reports uncaught errors. The following are handled by default and should not be connected to `QUnit.onUncaughtException()` a second time:

* HTML Runner: `window.onerror`
* HTML Runner: `window.addEventListener('unhandledrejection', …)`
* Browser Runner: `window.onerror`
* Browser Runner: `window.addEventListener('unhandledrejection', …)`
* QUnit CLI: `process.on('unhandledRejection', …)`
* QUnit CLI: `process.on('uncaughtException', …)`

Expand Down

0 comments on commit d034b2a

Please sign in to comment.