cases property

List<AuthStoreConformanceCase> cases
latefinal

Independently runnable cases in stable registration order.

Implementation

late final List<AuthStoreConformanceCase> cases =
    List<AuthStoreConformanceCase>.unmodifiable(<AuthStoreConformanceCase>[
      _case(
        id: 'users.create-find',
        description: 'creates users and resolves canonical identity',
        verify: _verifyUserCreateAndFind,
      ),
      _case(
        id: 'users.email-uniqueness',
        description: 'enforces email uniqueness at the write boundary',
        verify: _verifyUserEmailUniqueness,
      ),
      _case(
        id: 'users.email-update-atomicity',
        description: 'preserves email indexes when an update conflicts',
        verify: _verifyUserEmailUpdateAtomicity,
      ),
      _case(
        id: 'users.create-or-find-contention',
        description: 'creates one canonical email identity under contention',
        verify: _verifyUserCreateOrFindContention,
      ),
      _case(
        id: 'credentials.registration-lookup',
        description: 'registers and resolves password credentials atomically',
        verify: _verifyCredentialRegistration,
      ),
      _case(
        id: 'credentials.registration-contention',
        description: 'registers one credential owner under contention',
        verify: _verifyCredentialRegistrationContention,
      ),
      _case(
        id: 'credentials.user-lookup',
        description: 'resolves credentials through the optional user lookup',
        capability: AuthStoreConformanceCapability.credentialUserLookup,
        supports: (store) =>
            store.credentials is AuthCredentialUserLookupStore,
        verify: _verifyCredentialUserLookup,
      ),
      _case(
        id: 'accounts.uniqueness',
        description: 'keeps external account links globally unique',
        verify: _verifyAccountUniqueness,
      ),
      _case(
        id: 'accounts.link-contention',
        description: 'selects one canonical account owner under contention',
        verify: _verifyAccountLinkContention,
      ),
      _case(
        id: 'accounts.safe-unlink',
        description: 'prevents unlinking the last authentication method',
        capability:
            AuthStoreConformanceCapability.authenticationMethodMutation,
        supports: (store) => store is AuthOAuthAccountMutationStore,
        verify: _verifySafeAccountUnlink,
      ),
      _case(
        id: 'sessions.rotation',
        description: 'rotates sessions atomically and rejects replay',
        verify: _verifySessionRotation,
      ),
      _case(
        id: 'sessions.rotation-contention',
        description: 'commits exactly one session rotation replacement',
        verify: _verifySessionRotationContention,
      ),
      _case(
        id: 'sessions.revocation',
        description: 'revokes only user-owned sessions',
        verify: _verifySessionRevocation,
      ),
      _case(
        id: 'tokens.verification-single-use',
        description: 'consumes verification tokens at most once',
        verify: _verifyVerificationTokens,
      ),
      _case(
        id: 'tokens.verification-replay-contention',
        description: 'rejects concurrent verification-token replay',
        verify: _verifyVerificationTokenContention,
      ),
      _case(
        id: 'tokens.password-reset-single-use',
        description: 'replaces and consumes password-reset tokens atomically',
        verify: _verifyPasswordResetTokens,
      ),
      _case(
        id: 'tokens.password-reset-replay-contention',
        description: 'rejects concurrent password-reset token replay',
        verify: _verifyPasswordResetTokenContention,
      ),
      _case(
        id: 'oauth.challenge-replay-contention',
        description: 'consumes one OAuth challenge under contention',
        verify: _verifyOAuthChallengeContention,
      ),
      _case(
        id: 'jwt.version-rotation',
        description: 'tracks independent atomic JWT versions',
        verify: _verifyJwtVersions,
      ),
      _case(
        id: 'jwt.version-rotation-contention',
        description: 'returns distinct monotonic JWT rotation versions',
        verify: _verifyJwtVersionContention,
      ),
      _case(
        id: 'device-authorization.approve-lease-contention',
        description:
            'approves and completes one bounded device issuance lease',
        verify: _verifyDeviceAuthorizationContention,
      ),
      _case(
        id: 'email-otp.verification-contention',
        description: 'replaces and verifies an email OTP exactly once',
        verify: _verifyEmailOtpContention,
      ),
      _case(
        id: 'account-deletion.transaction',
        description: 'rolls back and retries transactional account deletion',
        capability: AuthStoreConformanceCapability.accountDeletion,
        supports: (store) => store is AuthUserDeletionCoordinatorHost,
        verify: _verifyAccountDeletionTransaction,
      ),
    ]);