From 6db9f27fc130b4395fa97765b1fccb88aadabd5c Mon Sep 17 00:00:00 2001 From: Andrew Bulat Date: Wed, 17 Jul 2024 12:01:55 +0100 Subject: [PATCH] Fix 'ably' mock does not export ErrorInfo --- __mocks__/ably/index.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/__mocks__/ably/index.ts b/__mocks__/ably/index.ts index 05fdc678..a3c455ba 100644 --- a/__mocks__/ably/index.ts +++ b/__mocks__/ably/index.ts @@ -91,8 +91,10 @@ class MockRealtime { } } +class MockErrorInfo extends ErrorInfo {} + // maintain the PresenceMessage class so tests can initialise it directly using // PresenceMessage.fromValues. MockRealtime.PresenceMessage = Rest.PresenceMessage; -export { MockRealtime as Realtime }; +export { MockRealtime as Realtime, MockErrorInfo as ErrorInfo };