plugin method

EmailOtpPlugin<TContext> plugin({
  1. Duration expiresIn = const Duration(minutes: 5),
  2. int allowedAttempts = 3,
  3. bool disableSignUp = false,
})

Creates a real email OTP plugin wired to this fixture.

Implementation

EmailOtpPlugin<TContext> plugin({
  Duration expiresIn = const Duration(minutes: 5),
  int allowedAttempts = 3,
  bool disableSignUp = false,
}) => EmailOtpPlugin<TContext>(
  sendCode: deliveries.capture,
  secret: _testOnlyHashKey,
  generateOtp: _nextCode,
  expiresIn: expiresIn,
  allowedAttempts: allowedAttempts,
  disableSignUp: disableSignUp,
);