Commit 387aa027 authored by Marcel Amirault's avatar Marcel Amirault

Merge branch 'mo-add-karma-example' into 'master'

Add karma junit documentation

See merge request gitlab-org/gitlab!47828
parents 0a719f47 9b12629a
......@@ -265,6 +265,23 @@ javascript:
- junit.xml
```
#### Karma
The [Karma-junit-reporter](https://github.com/karma-runner/karma-junit-reporter) npm package can generate test reports for JavaScript applications.
In the following `.gitlab-ci.yml` example, the `javascript` job uses Karma to generate the test reports:
```yaml
javascript:
stage: test
script:
- karma start --reporters junit
artifacts:
when: always
reports:
junit:
- junit.xml
```
## Viewing Unit test reports on GitLab
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/24792) in GitLab 12.5 behind a feature flag (`junit_pipeline_view`), disabled by default.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment