Skip to content

Commit 0b45e68

Browse files
authored
Merge pull request #269 from deepakkamboj/feature-addingtestsuitepathtotrx
feat(trx-generator.ts): add test suite path to codeBase field of trx …
2 parents 95f99e7 + c144151 commit 0b45e68

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/trx-generator.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ const renderTestSuiteResult = (
155155
const testId = uuidv4();
156156
const executionId = uuidv4();
157157
const fullTestName = getFullTestName(testResult);
158+
const filepath = path.relative("./", testSuiteResult.testFilePath);
158159

159160
// UnitTest
160161
const unitTest = testDefinitionsNode
@@ -164,7 +165,7 @@ const renderTestSuiteResult = (
164165
unitTest.ele("Execution").att("id", executionId);
165166
unitTest
166167
.ele("TestMethod")
167-
.att("codeBase", `Jest_${fullTestName}`)
168+
.att("codeBase", filepath)
168169
.att("name", fullTestName)
169170
.att("className", getTestClassName(testResult));
170171

0 commit comments

Comments
 (0)