MCPcopy Index your code
hub / github.com/coder/mux / expectError

Function expectError

src/node/runtime/coderLifecycleHooks.test.ts:84–90  ·  view source on GitHub ↗
(result: Result<void>)

Source from the content-addressed store, hash-verified

82}
83
84function expectError(result: Result<void>): string {
85 expect(result.success).toBe(false);
86 if (result.success) {
87 throw new Error("Expected lifecycle hook to fail");
88 }
89 return result.error;
90}
91
92describe("createCoderArchiveHook", () => {
93 it("does nothing when archive behavior is keep", async () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected