public UsersController(DocumentStores documentStore, ICustomFormsAuthentication customCustomFormsAuthentication, IOAuthAuthentication oAuthAuthentication) : base(documentStore) { Condition.Requires(customCustomFormsAuthentication).IsNotNull(); Condition.Requires(oAuthAuthentication).IsNotNull(); Condition.Requires(oAuthAuthentication.FacebookAppId).IsNotNullOrEmpty(); Condition.Requires(oAuthAuthentication.FacebookSecret).IsNotNullOrEmpty(); _customFormsAuthentication = customCustomFormsAuthentication; _facebookAppId = oAuthAuthentication.FacebookAppId; _facebookSecret = oAuthAuthentication.FacebookSecret; }
public UsersController(IDocumentSession documentSession, ICustomFormsAuthentication customCustomFormsAuthentication, IOAuthAuthentication oAuthAuthentication) : base(documentSession) { Condition.Requires(customCustomFormsAuthentication).IsNotNull(); Condition.Requires(oAuthAuthentication).IsNotNull(); Condition.Requires(oAuthAuthentication.FacebookAppId).IsNotNullOrEmpty(); Condition.Requires(oAuthAuthentication.FacebookSecret).IsNotNullOrEmpty(); _customFormsAuthentication = customCustomFormsAuthentication; _facebookAppId = oAuthAuthentication.FacebookAppId; _facebookSecret = oAuthAuthentication.FacebookSecret; }
public SevenDigitalCredentialsAuthProvider(IOAuthAuthentication auth, IUserApi userApi, TimeSpan sessionExpiry) : this(auth, userApi) { _sessionExpiry = sessionExpiry; }
public SevenDigitalCredentialsAuthProvider(IOAuthAuthentication auth, IUserApi userApi) { _auth = auth; _userApi = userApi; _logger = LogManager.GetLogger(GetType()); }
public void SetUp() { _userApi = MockRepository.GenerateStub <IUserApi>(); _userApi.Stub(x => x.CheckUserExists("")).IgnoreArguments().Return(true); _oAuthAuthentication = MockRepository.GenerateStub <IOAuthAuthentication>(); }