karma-sonarqube-unit-reporter icon indicating copy to clipboard operation
karma-sonarqube-unit-reporter copied to clipboard

hard coded test module definition prevents a brouder usage of the unit-reporter

Open thomasnikolay opened this issue 4 years ago • 1 comments

Our company use QUnit see https://en.wikipedia.org/wiki/QUnit for defining tests. Due the hardcoded https://github.com/tornaia/karma-sonarqube-unit-reporter/blob/83cd9a8c09e174427b26a793e48b609bcbe90088/src/file-util.js#L21 "describe(" is the tool limited to Jasmine or other tools which also using describe.

I created an additional feature to configure a string which is detected in the file.

Can you please add me as developer and can push the branch and create the pull request.

thomasnikolay avatar Jan 28 '21 10:01 thomasnikolay

This is very odd, indeed. Karma should never ever assume anything about the way tests are written. Reasons well described by the reporter already, but generated describe calls one way or another can easily break this logic, e.g., consider a Cucumber testing tool that generates describe calls through scenario implementations, and thus such calls will not happen directly in the test code.

rkrisztian avatar Jul 14 '22 10:07 rkrisztian