Skip to content

Commit 16d2b26

Browse files
committed
fixed the Railway deployment failing
1 parent 94d1187 commit 16d2b26

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

backend/src/lib/rate-limit.test.js

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,9 +79,15 @@ describe("redis client helpers", () => {
7979

8080
expect(first).toBe(second);
8181
expect(clientFactory).toHaveBeenCalledTimes(1);
82-
expect(clientFactory).toHaveBeenCalledWith({
83-
url: "redis://localhost:6379",
84-
});
82+
expect(clientFactory).toHaveBeenCalledWith(
83+
expect.objectContaining({
84+
url: "redis://localhost:6379",
85+
socket: expect.objectContaining({
86+
connectTimeout: 4000,
87+
reconnectStrategy: expect.any(Function),
88+
}),
89+
}),
90+
);
8591
expect(on).toHaveBeenCalledWith("error", expect.any(Function));
8692

8793
await connectRedisClient({

0 commit comments

Comments
 (0)