public async Task Should_toggle_feature_as_inactive() { var dto = new FeatureDTO(name: "buttonIsBlue", isActive: false); var existingFeature = new Feature(name: "buttonIsBlue", isActive: true); _featureRepository.GetByName("buttonIsBlue").Returns(existingFeature); await _featureDomainService.TogleFeature(dto); existingFeature.IsActive.Should().BeFalse(); }
public async Task ToggleFeature(FeatureModel featureModel) { await _featureDomainService.TogleFeature(new FeatureDTO(featureModel.Name, featureModel.IsActive)); await CommitAsync(); }