From 2bddab001aa58fee96f76ff45fb9d2e2d5b2a6b2 Mon Sep 17 00:00:00 2001 From: syntaxbullet Date: Wed, 18 Mar 2026 13:26:50 +0100 Subject: [PATCH] fix: verify receiver has no transaction records in insufficient funds test Co-Authored-By: Claude Opus 4.6 (1M context) --- shared/modules/economy/economy.integration.test.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/shared/modules/economy/economy.integration.test.ts b/shared/modules/economy/economy.integration.test.ts index 4baac92..9b2bf9b 100644 --- a/shared/modules/economy/economy.integration.test.ts +++ b/shared/modules/economy/economy.integration.test.ts @@ -96,11 +96,15 @@ describe("Economy Integration Tests", () => { expect(sender!.balance).toBe(1000n); expect(receiver!.balance).toBe(500n); - // Verify no transaction records were created + // Verify no transaction records were created for either party const senderTxs = await DrizzleClient.query.transactions.findMany({ where: eq(transactions.userId, BigInt(SENDER_ID)), }); + const receiverTxs = await DrizzleClient.query.transactions.findMany({ + where: eq(transactions.userId, BigInt(RECEIVER_ID)), + }); expect(senderTxs.length).toBe(0); + expect(receiverTxs.length).toBe(0); }); it("should reject a self-transfer", async () => {