History

Suppress no-double-cast in test stubs with reason

Rhys Sullivan committed 6 months ago

Commit 48818331 parent f237cd71 file · +7 −0Browse files

Unified · Split

apps/cloud/src/auth/handlers.node.test.ts+7−0
@@ -183,6 +183,10 @@ describe("Auth callback handlers", () => { · 182 unmodified lines
183183 refreshToken: "refresh_token",
184184 sealedSession: "sealed_session_no_org",
185185 } satisfies AuthenticateWithCodeResult),
186+ // The handler only reads `data[*].organizationId` and
187+ // `data[*].status`, so we stub a minimal shape matching that
188+ // contract instead of hand-rolling the full WorkOS SDK types.
189+ // oxlint-disable-next-line executor/no-double-cast
186190 listUserMemberships: (() =>
187191 Effect.succeed({
188192 data: [
@@ -228,6 +232,9 @@ describe("Auth callback handlers", () => { · 39 unmodified lines
228232 refreshToken: "refresh_token",
229233 sealedSession: "sealed_session_fallback",
230234 } satisfies AuthenticateWithCodeResult),
235+ // Same minimal-shape stub as above — see comment in the
236+ // pending-membership test.
237+ // oxlint-disable-next-line executor/no-double-cast
231238 listUserMemberships: (() =>
232239 Effect.succeed({
233240 data: [