Run Multimeter (.mmt) API tests, test suites, and generate documentation in GitHub Actions.
This is the Marketplace listing for Testlight. The same composite action also lives in the Multimeter repo at .github/actions/testlight.
- uses: actions/checkout@v4
- uses: mshobeyri/testlight-action@v1
with:
file: tests/suite.mmt
env-file: tests/env.mmt
preset: ci
report: junit
report-file: results/junit.xmlDocs: Install Testlight · Run in CI
| Input | Required | Default | Description |
|---|---|---|---|
file |
Yes | — | Path to the .mmt file |
command |
No | run |
run, doc, or print-js |
env-file |
No | — | Path to environment file |
preset |
No | — | Preset name from env file |
env |
No | — | Environment variables (KEY=VALUE pairs) |
input |
No | — | Input variables (KEY=VALUE pairs) |
example |
No | — | Specific example name or index |
report |
No | — | Report format: junit, html, md, mmt |
report-file |
No | — | Custom report output path. Parent directories are created. |
out |
No | — | Write result JSON to file. Parent directories are created. |
quiet |
No | false |
Minimal output |
log-level |
No | — | error, warn, info, debug, trace |
version |
No | latest |
mmt-testlight version to install (latest, beta, rc, or X.Y.Z) |
working-directory |
No | . |
Working directory |
| Output | Description |
|---|---|
result |
Path to result JSON (when out is set) |
report |
Path to report file (when report-file is set) |
exit-code |
Exit code of testlight |
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run tests
uses: mshobeyri/testlight-action@v1
with:
file: tests/suite.mmtjobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run tests
uses: mshobeyri/testlight-action@v1
with:
file: tests/suite.mmt
env-file: tests/env.mmt
preset: ci
report: junit
report-file: results/junit.xml
- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results
path: results/junit.xmljobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Generate docs
uses: mshobeyri/testlight-action@v1
with:
command: doc
file: api/catalog.mmt
out: public/api-docs.htmlApache License 2.0. See LICENSE.md.