mirror of
https://github.com/moltbot/moltbot.git
synced 2026-05-13 15:47:28 +00:00
test: tighten postinstall hotfix assertions
This commit is contained in:
@@ -254,9 +254,10 @@ describe("bundled plugin postinstall", () => {
|
||||
].join("\n"),
|
||||
);
|
||||
|
||||
expect(applyBaileysEncryptedStreamFinishHotfix({ packageRoot })).toMatchObject({
|
||||
expect(applyBaileysEncryptedStreamFinishHotfix({ packageRoot })).toEqual({
|
||||
applied: true,
|
||||
reason: "patched",
|
||||
targetPath: mediaFile,
|
||||
});
|
||||
const patchedText = await fs.readFile(mediaFile, "utf8");
|
||||
expect(patchedText).toContain(
|
||||
@@ -292,7 +293,7 @@ describe("bundled plugin postinstall", () => {
|
||||
].join("\n"),
|
||||
);
|
||||
|
||||
expect(applyBaileysEncryptedStreamFinishHotfix({ packageRoot })).toMatchObject({
|
||||
expect(applyBaileysEncryptedStreamFinishHotfix({ packageRoot })).toEqual({
|
||||
applied: false,
|
||||
reason: "already_patched",
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user