public SetTaxes(AmazonSyncSettings amazonSyncSettings, TaxSettings taxSettings, ISetTaxDetails taxRateManager) { _amazonSyncSettings = amazonSyncSettings; _taxSettings = taxSettings; _setTaxDetails = taxRateManager; }
public SetTaxDetailsTests() { _amazonSyncSettings = new AmazonSyncSettings() { UseDefaultTaxRateForShippingTax = true, TryCalculateVat = true }; _taxSettings = new TaxSettings() { TaxesEnabled = true, ShippingRateTaxesEnabled = true }; _taxRateManager = A.Fake<ITaxRateManager>(); _setTaxes = new SetTaxDetails(_amazonSyncSettings, _taxSettings, _taxRateManager); }
public SettingsControllerTests() { _configurationProvider = A.Fake<IConfigurationProvider>(); _amazonLogService = A.Fake<IAmazonLogService>(); _amazonAppSettings = A.Fake<AmazonAppSettings>(); _amazonSellerSettings = A.Fake<AmazonSellerSettings>(); _amazonSyncSettings = A.Fake<AmazonSyncSettings>(); _settingsController = new SettingsController(_configurationProvider, _amazonLogService, _amazonAppSettings, _amazonSellerSettings, _amazonSyncSettings); }
public void SettingsController_SyncPOST_ShouldSaveSettings() { var model = new AmazonSyncSettings(); var result = _settingsController.Sync_POST(model); result.Should().BeOfType<ViewResult>(); }
public void SettingsController_SyncPOST_ShouldCallAddLog() { var model = new AmazonSyncSettings(); var result = _settingsController.Sync_POST(model); A.CallTo(() => _amazonLogService.Add(AmazonLogType.SyncSettings, AmazonLogStatus.Update, null, null, null, null, null, null, null, null, string.Empty)).MustHaveHappened(); }