mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-28 05:16:23 -06:00
fix(test): narrow npm resolution timestamp
This commit is contained in:
@@ -115,7 +115,11 @@ describe("installFromNpmSpecArchiveWithInstaller", () => {
|
||||
const okResult = expectWrappedOkResult(result, { ok: true, target: "done" });
|
||||
expect(okResult.integrityDrift).toBeUndefined();
|
||||
expect(okResult.npmResolution.resolvedSpec).toBe(baseSpec);
|
||||
expect(Date.parse(okResult.npmResolution.resolvedAt)).not.toBeNaN();
|
||||
const resolvedAt = okResult.npmResolution.resolvedAt;
|
||||
if (!resolvedAt) {
|
||||
throw new Error("expected npm resolution timestamp");
|
||||
}
|
||||
expect(Date.parse(resolvedAt)).not.toBeNaN();
|
||||
expect(installFromArchive).toHaveBeenCalledWith({ archivePath: baseArchivePath });
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user