qa360 2.0.3 → 2.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/commands/history.js
CHANGED
|
@@ -53,13 +53,27 @@ export class QA360History {
|
|
|
53
53
|
const table = runs.map((run) => {
|
|
54
54
|
const duration = run.ended_at ? run.ended_at - run.started_at : null;
|
|
55
55
|
const durationStr = duration ? `${Math.round(duration / 1000)}s` : 'running';
|
|
56
|
+
// Format status without chalk for console.table compatibility
|
|
57
|
+
const statusIcon = run.status === 'passed' ? '✅' :
|
|
58
|
+
run.status === 'failed' ? '❌' :
|
|
59
|
+
run.status === 'running' ? '🏃' :
|
|
60
|
+
run.status === 'cancelled' ? '⏹️' :
|
|
61
|
+
run.status === 'error' ? '💥' : '⏭️';
|
|
62
|
+
// Extract pack name from pack_path or use a default
|
|
63
|
+
let packName = 'unknown';
|
|
64
|
+
if (run.pack_path) {
|
|
65
|
+
const parts = run.pack_path.split('/');
|
|
66
|
+
const fileName = parts[parts.length - 1];
|
|
67
|
+
// Remove .yml or .yaml extension
|
|
68
|
+
packName = fileName.replace(/\.(yml|yaml)$/, '');
|
|
69
|
+
}
|
|
56
70
|
return {
|
|
57
71
|
'Run ID': run.id.substring(0, 8),
|
|
58
72
|
'Started': new Date(run.started_at).toLocaleString(),
|
|
59
|
-
'Status':
|
|
73
|
+
'Status': statusIcon + ' ' + run.status.toUpperCase(),
|
|
60
74
|
'Trust': run.trust_score ? `${run.trust_score}%` : '-',
|
|
61
75
|
'Duration': durationStr,
|
|
62
|
-
'Pack':
|
|
76
|
+
'Pack': packName,
|
|
63
77
|
'Pinned': run.pinned ? '📌' : ''
|
|
64
78
|
};
|
|
65
79
|
});
|
|
@@ -761,7 +761,7 @@ export class Phase3Runner {
|
|
|
761
761
|
try {
|
|
762
762
|
// Begin run in vault (returns actual runId used)
|
|
763
763
|
const { runId: vaultRunId } = await this.vault.beginRun({
|
|
764
|
-
pack_path: '
|
|
764
|
+
pack_path: `${this.pack.name || 'pack'}.yaml`,
|
|
765
765
|
pack_hash: this.hashPack(result.pack)
|
|
766
766
|
});
|
|
767
767
|
// Finish run with final status
|