Skip to content

Commit

Permalink
Update manage-integration-check.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
frazarshad authored Aug 1, 2024
1 parent 0be9dd1 commit 4de46a6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/manage-integration-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ jobs:
external_id,
})
core.debug(`integration-test-result check runs: ${JSON.stringify(runs, null, 2)}`);
const descRuns = runs.sort((a, b) => Date.parse(b.started_at) - Date.parse(a.started_at));
const filtRuns = runs.filter(run => run.external_id === external_id);
const descRuns = filtRuns.sort((a, b) => Date.parse(b.started_at) - Date.parse(a.started_at));
console.log(JSON.stringify(runs, null, 2));
const run = descRuns[0];
if (run) {
Expand Down Expand Up @@ -66,7 +67,7 @@ jobs:
external_id,
})
core.debug(`integration-test-result check runs: ${JSON.stringify(runs, null, 2)}`);
const filtRuns = runs.filter(run => run.status !== 'completed');
const filtRuns = runs.filter(run => run.status !== 'completed' && run.external_id === external_id);
const descRuns = filtRuns.sort((a, b) => Date.parse(b.started_at) - Date.parse(a.started_at));
console.log(context.payload.workflow_run.rerun_url, context.payload.workflow_run.run_attempt, context.payload.workflow_run.run_number);
console.log(JSON.stringify(runs, null, 2));
Expand Down

0 comments on commit 4de46a6

Please sign in to comment.