Gathering detailed insights and metrics for karma-sonarqube-reporter
Gathering detailed insights and metrics for karma-sonarqube-reporter
Gathering detailed insights and metrics for karma-sonarqube-reporter
Gathering detailed insights and metrics for karma-sonarqube-reporter
karma-sonarqube-unit-reporter
A Karma plugin. Report results in sonar-unit-tests xml format.
karma-jasmine-html-reporter
A Karma plugin. Dynamically displays tests results at debug.html page
babel-plugin-istanbul
A babel plugin that adds istanbul instrumentation to ES6 code
karma-junit-reporter
A Karma plugin. Report results in junit xml format.
npm install karma-sonarqube-reporter
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
7 Stars
303 Commits
8 Forks
3 Watching
59 Branches
7 Contributors
Updated on 04 Nov 2023
JavaScript (69.08%)
TypeScript (25.12%)
HTML (4.9%)
Shell (0.62%)
CSS (0.28%)
Cumulative downloads
Total Downloads
Last day
27.8%
7,746
Compared to previous day
Last week
10.4%
33,030
Compared to previous week
Last month
2.9%
132,548
Compared to previous month
Last year
30.6%
1,797,803
Compared to previous year
Karma reporter plugin for generating SonarQube generic test reports.
Node.js >= 8.10.0
npm install karma-sonarqube-reporter --save-dev
Adjust your karma.conf.js
file:
Create a new plugin entry
1plugins: [ 2 require('karma-sonarqube-reporter') 3]
Add configuration parameters
1// Default configuration 2sonarqubeReporter: { 3 basePath: 'src/app', // test files folder 4 filePattern: '**/*spec.ts', // test files glob pattern 5 encoding: 'utf-8', // test files encoding 6 outputFolder: 'reports', // report destination 7 legacyMode: false, // report for Sonarqube < 6.2 (disabled) 8 reportName: (metadata) => { // report name callback, but accepts also a 9 // string (file name) to generate a single file 10 /** 11 * Report metadata array: 12 * - metadata[0] = browser name 13 * - metadata[1] = browser version 14 * - metadata[2] = platform name 15 * - metadata[3] = platform version 16 */ 17 return metadata.concat('xml').join('.'); 18 } 19}
Activate sonarqube
reporter
1reporters: ['sonarqube']
Click here to see a full example.
If your project uses Angular CLI run ng test
and check the output folder.
1$ ls reports 2chrome.65.0.3325.linux.0.0.0.xml 3firefox.54.0.0.linux.0.0.0.xml
The current report files' schema is defined on the SonarQube Generic Test Data page.
Add to your sonar-project.properties
one of the following properties:
Legacy Mode | Property |
---|---|
false | sonar.testExecutionReportPaths |
true | sonar.genericcoverage.unitTestReportPaths |
Note report paths should be passed in a comma-delimited.
Finally, start SonarQube Scanner on your project folder.
Contributions are welcome!
That's all!
Thanks goes to these wonderful people (emoji key):
Fernando Costa 💻 🐛 📖 | Sohan Soni 💻 | Steffen Giers 💻 | Maurycy Gosciniak 🐛 | Fabio 💻 🐛 | Héla Ben Khalfallah 🐛 |
Esche 🐛 | Jérémy Bardon 💻 | Paulius Paplauskas 💻 |
This project follows the all-contributors specification. Contributions of any kind welcome!
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
SAST tool detected but not run on all commits
Details
Reason
Found 1/4 approved changesets -- score normalized to 2
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
103 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-25
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More