public UsersController(IUserRegisterer userRegisterer, IAuthTokenGenerator authTokenGenerator, IUserRetriever userRetriever, ITransformer transformer) { this.userRegisterer = userRegisterer; this.authTokenGenerator = authTokenGenerator; this.userRetriever = userRetriever; this.transformer = transformer; }
public OfferingSaleCanceller(IOfferingSaleCancellerConfiguration configuration, ISerializer serializer, IDeserializer deserializer, IHttpClientCreator httpClientCreator, IAuthTokenGenerator authTokenGenerator) { _configuration = configuration ?? throw new ArgumentNullException(nameof(configuration)); _serializer = serializer ?? throw new ArgumentNullException(nameof(serializer)); _deserializer = deserializer ?? throw new ArgumentNullException(nameof(deserializer)); _httpClientCreator = httpClientCreator ?? throw new ArgumentNullException(nameof(httpClientCreator)); _authTokenGenerator = authTokenGenerator ?? throw new ArgumentNullException(nameof(authTokenGenerator)); }
public void When_AuthTokenGenerator_Is_Null_Then_Constructor_Throws_ArgumentNullException() { // set up IAuthTokenGenerator authTokenGenerator = null; // execute var ex = Assert.Throws <ArgumentNullException>(() => new OfferingResultWriter(_configuration.Object, _serializer.Object, _deserializer.Object, _httpClientCreator.Object, authTokenGenerator, _vendorCredentials.Object)); // verify Assert.Equal("authTokenGenerator", ex.ParamName); }
public AuthService( UserRepository usersRepository, IRepository <University> universityRepository, IRepository <UniversityAdmin> universityAdminRepository, IRepository <Teacher> teachersRepository, IRepository <Student> studentsRepository, IAuthTokenGenerator tokenGenerator, IRefreshTokenFactory refreshTokenFactory) { this.usersRepository = usersRepository; this.universityAdminRepository = universityAdminRepository; this.teachersRepository = teachersRepository; this.studentsRepository = studentsRepository; this.universityRepository = universityRepository; this.tokenGenerator = tokenGenerator; this.refreshTokenFactory = refreshTokenFactory; }
public AuthTokenValidator(IAuthTokenGenerator authTokenGenerator, IDataContext dataContext) { this.authTokenGenerator = authTokenGenerator; this.dataContext = dataContext; }
public AuthService(UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, IAuthTokenGenerator tokenGenerator) { _userManager = userManager; _signInManager = signInManager; _tokenGenerator = tokenGenerator; }
public LoginCommandHandler(IAuthTokenGenerator authTokenGenerator, IRoleService roleService, IUserAuthService userAuthService) { _authTokenGenerator = authTokenGenerator; _roleService = roleService; _userAuthService = userAuthService; }
public OfferingSaleCanceller(IOfferingSaleCancellerConfiguration configuration, ISerializer serializer, IDeserializer deserializer, IHttpClientCreator httpClientCreator, IAuthTokenGenerator authTokenGenerator, IVendorCredentials defaultCredentials) : this(configuration, serializer, deserializer, httpClientCreator, authTokenGenerator) { _defaultCredentials = defaultCredentials; }
public UserSessionsController(ApplicationUserManager applicationUserManager, IAuthTokenGenerator authTokenGenerator) { this.applicationUserManager = applicationUserManager; this.authTokenGenerator = authTokenGenerator; }