Skip to content

Commit

Permalink
Aggregate summary, duration, and removing failure case
Browse files Browse the repository at this point in the history
  • Loading branch information
philrenaud committed Nov 28, 2024
1 parent f98bd61 commit dad20cf
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/test-ui.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,10 +111,16 @@ jobs:
node -e "
const fs = require('fs');
const results = [];
let duration = 0;
let aggregateSummary = { total: 0, passed: 0, failed: 0 };
for (let i = 1; i <= 4; i++) {
try {
const data = JSON.parse(fs.readFileSync('../test-results/test-results-' + i + '/test-results.json'));
results.push(...data.tests);
duration += data.duration;
aggregateSummary.total += data.summary.total;
aggregateSummary.passed += data.summary.passed;
aggregateSummary.failed += data.summary.failed;
} catch (err) {
console.error('Error reading partition ' + i + ':', err);
}
Expand All @@ -123,10 +129,11 @@ jobs:
timestamp: new Date().toISOString(),
sha: process.env.GITHUB_SHA,
summary: {
total: results.length,
passed: results.filter(r => r.passed).length,
failed: results.filter(r => !r.passed).length
total: aggregateSummary.total,
passed: aggregateSummary.passed,
failed: aggregateSummary.failed
},
duration,
tests: results
}, null, 2));
"
Expand Down
2 changes: 1 addition & 1 deletion ui/tests/acceptance/variables-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ module('Acceptance | variables', function (hooks) {
assert.ok(confirmFired, 'Confirm fired when leaving with unsaved form');
assert.equal(
currentURL(),
'/variables/var/Auto-conflicting%20Variable@default/editte',
'/variables/var/Auto-conflicting%20Variable@default/edit',
'Opted to stay, did not leave page'
);

Expand Down

0 comments on commit dad20cf

Please sign in to comment.