From 1e9d5d548a4f095c7398e506d9fa7f18b34b30a4 Mon Sep 17 00:00:00 2001 From: cliffhall Date: Fri, 25 Apr 2025 09:28:16 -0400 Subject: [PATCH] Update protocol version * Added types.test.ts - "should have correct latest protocol version" - "should have correct supported protocol versions" --- src/types.test.ts | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/types.test.ts diff --git a/src/types.test.ts b/src/types.test.ts new file mode 100644 index 00000000..bdb5ffb3 --- /dev/null +++ b/src/types.test.ts @@ -0,0 +1,17 @@ +import { LATEST_PROTOCOL_VERSION, SUPPORTED_PROTOCOL_VERSIONS} from "./types.js"; + +describe("Types", () => { + + test("should have correct latest protocol version", () => { + expect(LATEST_PROTOCOL_VERSION).toBeDefined(); + expect(LATEST_PROTOCOL_VERSION).toBe("2025-03-26"); + }); + test("should have correct supported protocol versions", () => { + expect(SUPPORTED_PROTOCOL_VERSIONS).toBeDefined(); + expect(SUPPORTED_PROTOCOL_VERSIONS).toBeInstanceOf(Array); + expect(SUPPORTED_PROTOCOL_VERSIONS).toContain(LATEST_PROTOCOL_VERSION); + expect(SUPPORTED_PROTOCOL_VERSIONS).toContain("2024-11-05"); + expect(SUPPORTED_PROTOCOL_VERSIONS).toContain("2024-10-07"); + }); + +});