fix: delegate runtime-ready to post-flush closeout
This commit is contained in:
@@ -608,8 +608,13 @@ test("v03 render keeps node identity as data instead of generated structure", as
|
||||
assert.ok(generatedPaths.includes("runtime-v03/configmaps.yaml"));
|
||||
assert.ok(generatedPaths.includes("runtime-v03/external-secrets.yaml"));
|
||||
const pipeline = await readFile(path.join(outDir, "tekton-v03", "pipeline.yaml"), "utf8");
|
||||
const pipelineJson = JSON.parse(pipeline);
|
||||
assert.match(pipeline, /--external-service-report-dir \/workspace\/source\/service-results/u);
|
||||
assert.match(pipeline, /--ci-plan-path \/workspace\/source\/affected-services\.json/u);
|
||||
const gitopsPromote = taskByName(pipelineJson, "gitops-promote");
|
||||
const gitopsPromoteScript = gitopsPromote.taskSpec.steps[0].script;
|
||||
assert.match(gitopsPromoteScript, /if \[ "\$runtime_lane" = "true" \]; then\s+printf 'false' > \/tekton\/results\/runtime-ready-required/u);
|
||||
assert.match(gitopsPromoteScript, /delegated-post-flush-closeout/u);
|
||||
assert.ok(!generatedPaths.includes("runtime-v03/postgres.yaml"));
|
||||
for (const relativePath of generatedPaths) {
|
||||
assert.doesNotMatch(relativePath, /g14/i, `legacy node token leaked into generated path ${relativePath}`);
|
||||
|
||||
Reference in New Issue
Block a user