ci(release): stabilize beta validation assertions · openclaw/openclaw@1c3ff34
steipete
·
2026-05-19
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -37,6 +37,10 @@ function expectZeroNpmJsonConfig(value: unknown): void {
|
37 | 37 | expect(value === 0 || value === "0").toBe(true); |
38 | 38 | } |
39 | 39 | |
| 40 | +function expectUnsetOrZeroNpmJsonConfig(value: unknown): void { |
| 41 | +expect(value == null || value === false || value === 0 || value === "0").toBe(true); |
| 42 | +} |
| 43 | + |
40 | 44 | describe("npm project install env", () => { |
41 | 45 | it("uses an absolute POSIX script shell for npm lifecycle scripts", () => { |
42 | 46 | withMockedPlatform("linux", () => { |
@@ -376,7 +380,7 @@ describe("npm project install env", () => {
|
376 | 380 | npmConfig.before === false || |
377 | 381 | typeof npmConfig.before === "string", |
378 | 382 | ).toBe(true); |
379 | | -expectZeroNpmJsonConfig(npmConfig["min-release-age"]); |
| 383 | +expectUnsetOrZeroNpmJsonConfig(npmConfig["min-release-age"]); |
380 | 384 | } finally { |
381 | 385 | fsSync.rmSync(dir, { recursive: true, force: true }); |
382 | 386 | } |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -98,10 +98,15 @@ describe("test-install-sh-docker", () => {
|
98 | 98 | it("allows repository branch history and release tags for secret-backed Docker release checks", () => { |
99 | 99 | const workflow = readFileSync(LIVE_E2E_WORKFLOW_PATH, "utf8"); |
100 | 100 | |
101 | | -expect(workflow).toContain("git fetch --no-tags origin '+refs/heads/*:refs/remotes/origin/*'"); |
102 | 101 | expect(workflow).toContain('git rev-parse --verify "${INPUT_REF}^{commit}"'); |
| 102 | +expect(workflow).toContain( |
| 103 | +'git merge-base --is-ancestor "$selected_sha" refs/remotes/origin/main', |
| 104 | +); |
103 | 105 | expect(workflow).toContain("repository-branch-history"); |
104 | 106 | expect(workflow).toContain("git tag --points-at \"$selected_sha\" | grep -Eq '^v'"); |
| 107 | +expect(workflow).toContain( |
| 108 | +"git for-each-ref --format='%(refname:short)' --contains \"$selected_sha\" refs/remotes/origin", |
| 109 | +); |
105 | 110 | expect(workflow).toContain("reachable from an OpenClaw branch or release tag"); |
106 | 111 | }); |
107 | 112 | |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。