Skip to content

Commit

Permalink
Do not include interop in at risk.
Browse files Browse the repository at this point in the history
  • Loading branch information
aljones15 committed Sep 18, 2024
1 parent 95d8078 commit 45735c3
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/extensions.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ export const extensions = {

function getAtRisk({matrices}) {
const riskRows = [];
for(const {rows} of matrices) {
for(const {rows, title} of matrices) {
// do not include interop results in at risk
if(title.includes('(interop)')) {
continue;
}
for(const row of rows) {
// if all tests were skipped then don't add it to at risk
if(row?.cells.every(cell => cell.state === 'pending')) {
Expand All @@ -38,7 +42,7 @@ function getAtRisk({matrices}) {
// only include at risk rows
if(atRisk(row?.cells)) {
// do not include duplicate statements
if(!riskRows.find(r => r.id === row.id)) {
if(!riskRows.some(r => r.id === row.id)) {
const riskRow = {...row};
riskRow.cells = [{state: 'failed'}];
riskRows.push(riskRow);
Expand Down

0 comments on commit 45735c3

Please sign in to comment.