mirror of
https://github.com/dorny/test-reporter.git
synced 2026-03-22 16:02:13 +01:00
NUnit Legacy: clean up suite/group names
This commit is contained in:
parent
0850bc862a
commit
e89b2f3e47
5 changed files with 34 additions and 34 deletions
|
|
@ -78,7 +78,7 @@ export class DotnetNunitLegacyParser implements TestParser {
|
|||
// But ignore "Theory" suites.
|
||||
const suitesWithoutTheories = suitePath.filter(suite => suite.$.type !== 'Theory')
|
||||
const suiteName = suitesWithoutTheories
|
||||
.slice(0, suitesWithoutTheories.length - 1)
|
||||
.filter(suite => suite.$.type !== 'Assembly' && suite.$.type !== 'Project')
|
||||
.map(suite => suite.$.name)
|
||||
.join('.')
|
||||
const groupName = suitesWithoutTheories[suitesWithoutTheories.length - 1].$.name
|
||||
|
|
@ -97,7 +97,7 @@ export class DotnetNunitLegacyParser implements TestParser {
|
|||
|
||||
existingGroup.tests.push(
|
||||
new TestCaseResult(
|
||||
testCase.$.name,
|
||||
testCase.$.name.startsWith(suiteName + '.') ? testCase.$.name.substring(suiteName.length + 1) : testCase.$.name,
|
||||
this.getTestExecutionResult(testCase),
|
||||
parseFloat(testCase.$.time),
|
||||
this.getTestCaseError(testCase)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue