Skip to content

Commit bd43c65

Browse files
author
Yash Ladha
committed
chore: append sessionId in name
1 parent 07c1ccf commit bd43c65

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

index.js

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,13 +50,16 @@ var myReporter = {
5050
const suite = suites[suiteIndex]
5151
const suiteName = this.prepareName(suite.description)
5252
const testSuite = builder.ele("testsuite", {name: suiteName})
53+
let SESSION_ID;
5354
for (let specIndex in suite.specs) {
5455
const test = suite.specs[specIndex]
5556
const testName = this.prepareName(test.description)
5657
const { sessionID } = test;
57-
const testCase = testSuite.ele("testcase",{name: `${sessionID}_${testName}`, id: `${suiteName}.${testName}{0}`, index: 0 });
58+
SESSION_ID = sessionID;
59+
const testCase = testSuite.ele("testcase",{name: testName, id: `${suiteName}_${sessionID}.${testName}{0}`, index: 0 });
5860
testCase.ele("session", {}, sessionID);
5961
}
62+
testSuite.att('name', `${suiteName}_${SESSION_ID}`);
6063
}
6164
return builder.end({ pretty: true});
6265
},

0 commit comments

Comments
 (0)