task-h.5.3
This commit is contained in:
@@ -30,11 +30,13 @@ async function main() {
|
||||
'placeholder-integrity-report.json'
|
||||
);
|
||||
const payloadReport = await readReport<Record<string, unknown>>('payload-parity-report.json');
|
||||
const runtimeReport = await readReport<Record<string, unknown>>('runtime-payload-report.json');
|
||||
const snapshotReport = await readReport<Record<string, unknown>>('signature-audit-report.json');
|
||||
const statuses = [
|
||||
String(templateVersionReport?.overallStatus ?? 'WARNING'),
|
||||
String(placeholderReport?.overallStatus ?? 'WARNING'),
|
||||
String(payloadReport?.overallStatus ?? 'WARNING'),
|
||||
String(runtimeReport?.overallStatus ?? 'WARNING'),
|
||||
String(snapshotReport?.overallStatus ?? 'WARNING')
|
||||
] as Array<'PASS' | 'WARNING' | 'FAIL'>;
|
||||
const overallStatus = summarizeIssues(statuses);
|
||||
@@ -64,6 +66,7 @@ async function main() {
|
||||
artifacts: {
|
||||
templateVersionReport: 'template-version-report.json',
|
||||
placeholderIntegrityReport: 'placeholder-integrity-report.json',
|
||||
runtimePayloadReport: 'runtime-payload-report.json',
|
||||
payloadParityReport: 'payload-parity-report.json',
|
||||
topicRuntimeReport: 'topic-runtime-report.json',
|
||||
signatureAuditReport: 'signature-audit-report.json'
|
||||
@@ -71,9 +74,23 @@ async function main() {
|
||||
statuses: {
|
||||
templateVersion: templateVersionReport?.overallStatus ?? 'WARNING',
|
||||
placeholderIntegrity: placeholderReport?.overallStatus ?? 'WARNING',
|
||||
runtimePayload: runtimeReport?.overallStatus ?? 'WARNING',
|
||||
payloadParity: payloadReport?.overallStatus ?? 'WARNING',
|
||||
topicRuntime: topicRuntimeReport.overallStatus,
|
||||
approvedSnapshotParity: snapshotReport?.overallStatus ?? 'WARNING'
|
||||
approvedSnapshotParity: snapshotReport?.overallStatus ?? 'WARNING',
|
||||
staticLabels: runtimeReport?.staticLabelsStatus ?? 'WARNING'
|
||||
},
|
||||
priceTable: {
|
||||
present: Boolean(payload.templateInput.quotation_price_data),
|
||||
rowCount: Array.isArray(payload.templateInput.quotation_price_data)
|
||||
? payload.templateInput.quotation_price_data.length
|
||||
: 0,
|
||||
parity: payloadReport?.priceTableParity ?? false,
|
||||
status:
|
||||
Array.isArray(payload.templateInput.quotation_price_data) &&
|
||||
(payloadReport?.priceTableParity ?? false)
|
||||
? 'PASS'
|
||||
: 'FAIL'
|
||||
}
|
||||
};
|
||||
const artifactPath = await writeAuditArtifact('summary.json', summary);
|
||||
@@ -88,14 +105,20 @@ async function main() {
|
||||
'',
|
||||
`- Template Version Integrity: ${summary.statuses.templateVersion}`,
|
||||
`- Placeholder Integrity: ${summary.statuses.placeholderIntegrity}`,
|
||||
`- Runtime Payload: ${summary.statuses.runtimePayload}`,
|
||||
`- Payload Parity: ${summary.statuses.payloadParity}`,
|
||||
`- Topic Runtime: ${summary.statuses.topicRuntime}`,
|
||||
`- Approved Snapshot Parity: ${summary.statuses.approvedSnapshotParity}`,
|
||||
`- Static Labels: ${summary.statuses.staticLabels}`,
|
||||
`- Price Table Present: ${summary.priceTable.present ? 'Yes' : 'No'}`,
|
||||
`- Price Table Status: ${summary.priceTable.status}`,
|
||||
`- Price Table Parity: ${summary.priceTable.parity ? 'Yes' : 'No'}`,
|
||||
'',
|
||||
'## Artifact Files',
|
||||
'',
|
||||
`- ${summary.artifacts.templateVersionReport}`,
|
||||
`- ${summary.artifacts.placeholderIntegrityReport}`,
|
||||
`- ${summary.artifacts.runtimePayloadReport}`,
|
||||
`- ${summary.artifacts.payloadParityReport}`,
|
||||
`- ${summary.artifacts.topicRuntimeReport}`,
|
||||
`- ${summary.artifacts.signatureAuditReport}`
|
||||
|
||||
Reference in New Issue
Block a user