mmo-js-tests
1 symbol · generated 5 Oct 2026
mmo-js-tests
mmo-js-tests.jhs:1The javascript test suite, run from the page.
- Extends
- CustomShadowElement
Index
| filter | the namespace the picker opens on; empty means all of them | |
| auto | run once, on connect. | |
| constructor() | ||
| init() | ||
| message(state, message) | Set the strip's state and its message. | |
| request(path, method, body) | Call one of the controller's routes. | |
| load() | Read the namespaces the suite holds, and fill the picker. | |
| run(namespace) | Run the suite, or the one namespace given. | |
| setReport(report) | Draw a report. | |
| toggleAll() | Open or close every file at once. | |
| toggleFailures() | Show every test, or only what failed. |
Attributes2
filter
mmo-js-tests.jhsthe namespace the picker opens on; empty means all of them
filter=""
auto
mmo-js-tests.jhsrun once, on connect. Write auto="false" to wait for the button.
auto
Methods9
constructor()
mmo-js-tests.jhs:129init()
mmo-js-tests.jhs:135message(state, message)
mmo-js-tests.jhs:157Set the strip's state and its message.
| state | string | - '', 'busy', 'ok' or 'error'; it is also the css class |
| message | string |
request(path, method, body)
mmo-js-tests.jhs:173Call one of the controller's routes.
| path | string | - jsTests or jsTestsRun |
| method = 'GET' | string | |
| body = null | ?object | |
| returns | Promise | the route's payload |
load()
mmo-js-tests.jhs:194Read the namespaces the suite holds, and fill the picker.
| returns | Promise |
run(namespace)
mmo-js-tests.jhs:219Run the suite, or the one namespace given.
| namespace = null | ?string | - what to run; the picker's own value when omitted |
| returns | Promise |
setReport(report)
mmo-js-tests.jhs:248Draw a report.
| report | object | - what run.js --json printed |
| returns | void |
toggleAll()
mmo-js-tests.jhs:301Open or close every file at once.
| returns | void |
toggleFailures()
mmo-js-tests.jhs:316Show every test, or only what failed. The filtering is a class on the host, so it costs no re-render: a report of 356 rows is drawn once and narrowed by css.
| returns | void |