Skip to content

Commit

Permalink
Fix #27 Pending tests marks suite as failed
Browse files Browse the repository at this point in the history
  • Loading branch information
Oleg Shulimov committed Feb 24, 2022
1 parent b75c316 commit 5c53249
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -149,11 +149,7 @@ class WdioTeamcityReporter extends WdioReporter {
onSuiteEnd (suiteStats) {
const pendingTests = Object.values(suiteStats.tests).filter(test => test.state === 'pending');
pendingTests.forEach(testStat => {
testStat.error = testStat.error || {
message: 'Test is considered as failed, as it is still "pending" on suite end.',
stack: '',
};
this._m('##teamcity[testFailed name=\'{name}\' message=\'{error}\' details=\'{stack}\' flowId=\'{id}\']', testStat);
this._m('##teamcity[testIgnored name=\'{name}\' message=\'skipped\' flowId=\'{id}\']', testStat);
});

this._m('##teamcity[testSuiteFinished name=\'{name}\' flowId=\'{id}\']', suiteStats);
Expand Down

0 comments on commit 5c53249

Please sign in to comment.