mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-11 23:00:42 +00:00
test: tighten ci changed scope injection assertion
This commit is contained in:
@@ -578,7 +578,14 @@ describe("detectChangedScope", () => {
|
||||
? `HEAD & echo injected > "${markerPath}" & rem`
|
||||
: `HEAD; touch "${markerPath}" #`;
|
||||
|
||||
expect(() => listChangedPaths(injectedBase, "HEAD")).toThrow();
|
||||
let error: unknown;
|
||||
try {
|
||||
listChangedPaths(injectedBase, "HEAD");
|
||||
} catch (caught) {
|
||||
error = caught;
|
||||
}
|
||||
expect(error).toBeInstanceOf(Error);
|
||||
expect((error as Error).message).toContain(injectedBase);
|
||||
expect(fs.existsSync(markerPath)).toBe(false);
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user