AccountManagement.TestHelpers.Scenarios.RegisterAccountScenario.Execute C# (CSharp) Method

Execute() public method

public Execute ( ) : Account
return Account
        public Account Execute()
        {
            return _container.ExecuteUnitOfWork(
                () =>
                {
                    var repository = _container.Resolve<IAccountRepository>();
                    var duplicateAccountChecker = _container.Resolve<IDuplicateAccountChecker>();
                    var registered = Account.Register(Email, Password, AccountId, repository, duplicateAccountChecker);

                    return registered;
                });

        }
    }

Usage Example

コード例 #1
0
 public ChangePasswordScenario(IWindsorContainer container)
 {
     _container = container;
     NewPassword = new Password(NewPasswordAsString);
     var registerAccountScenario = new RegisterAccountScenario(container);
     Account = registerAccountScenario.Execute();
     OldPassword = registerAccountScenario.PasswordAsString;
 }
All Usage Examples Of AccountManagement.TestHelpers.Scenarios.RegisterAccountScenario::Execute
RegisterAccountScenario