mirror of
https://github.com/diegosouzapw/OmniRoute.git
synced 2026-09-22 06:42:19 +03:00
fix(ci): retain supervised gate logs and receipts
This commit is contained in:
4
.github/workflows/nightly-release-green.yml
vendored
4
.github/workflows/nightly-release-green.yml
vendored
@@ -247,7 +247,9 @@ jobs:
|
||||
path: |
|
||||
release-green.json
|
||||
release-green.log
|
||||
_artifacts/release-green/
|
||||
if-no-files-found: error
|
||||
retention-days: 14
|
||||
|
||||
- name: Enforce validation verdict
|
||||
if: always()
|
||||
@@ -388,7 +390,9 @@ jobs:
|
||||
path: |
|
||||
main-green.json
|
||||
main-green.log
|
||||
_artifacts/release-green/
|
||||
if-no-files-found: error
|
||||
retention-days: 14
|
||||
|
||||
- name: Enforce validation verdict
|
||||
if: always()
|
||||
|
||||
22
tests/unit/build/gate-process-artifact.test.ts
Normal file
22
tests/unit/build/gate-process-artifact.test.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
import test from "node:test";
|
||||
import assert from "node:assert/strict";
|
||||
import { readFileSync } from "node:fs";
|
||||
import { parse } from "yaml";
|
||||
|
||||
test("both observers retain incremental command logs even on failure", () => {
|
||||
const workflow = parse(
|
||||
readFileSync(
|
||||
new URL("../../../.github/workflows/nightly-release-green.yml", import.meta.url),
|
||||
"utf8"
|
||||
)
|
||||
);
|
||||
for (const id of ["release-green", "main-green"]) {
|
||||
const upload = workflow.jobs[id].steps.find(
|
||||
(step: { name?: string }) => step.name === "Upload report artifact"
|
||||
);
|
||||
assert.equal(upload.if, "always()");
|
||||
assert.match(upload.with.path, /_artifacts\/release-green\//);
|
||||
assert.equal(upload.with["if-no-files-found"], "error");
|
||||
assert.equal(upload.with["retention-days"], 14);
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user