public void WhenNewBankAccountIsCreated() { var licensee = BrandHelper.CreateLicensee(); var brand = BrandHelper.CreateBrand(licensee, isActive: true); var bankAccount = PaymentHelper.CreateBankAccount(brand.Id, brand.DefaultCurrency); ScenarioContext.Current.Add("bankAccountId", bankAccount.Id); }
public void Cannot_Activate_Brand_Without_Country() { var licensee = BrandHelper.CreateLicensee(); var brandId = BrandHelper.CreateBrand(licensee, PlayerActivationMethod.Automatic); BrandHelper.AssignCurrency(brandId, Currency.Code); BrandHelper.AssignCulture(brandId, Culture.Code); PaymentHelper.CreateBank(brandId, Country.Code); PaymentHelper.CreateBankAccount(brandId, Currency.Code); PaymentHelper.CreatePaymentLevel(brandId, Currency.Code); BrandHelper.CreateWallet(licensee.Id, brandId); BrandHelper.CreateVipLevel(brandId); Action action = () => BrandCommands.ActivateBrand(new ActivateBrandRequest { BrandId = brandId, Remarks = "remarks" }); action.ShouldThrow <ValidationException>() .Where(x => x.Message.Contains("noAssignedCountry")); }