AccountManagement.TestHelpers.Scenarios.RegisterAccountScenario.Execute C# (CSharp) 메소드

Execute() 공개 메소드

public Execute ( ) : Account
리턴 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

 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