File tree Expand file tree Collapse file tree 1 file changed +17
-1
lines changed
WooCommerce/WooCommerceTests/ViewRelated/Settings Expand file tree Collapse file tree 1 file changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -184,7 +184,23 @@ final class SettingsViewModelTests: XCTestCase {
184184 XCTAssertFalse ( viewModel. sections. contains { $0. rows. contains ( SettingsViewController . Row. domain) } )
185185 }
186186
187- func test_domain_is_hidden_when_domainSettings_feature_is_enabled_and_site_is_wpcom( ) {
187+ func test_domain_is_hidden_when_domainSettings_feature_is_enabled_and_site_is_not_wpcom( ) {
188+ // Given
189+ let featureFlagService = MockFeatureFlagService ( isDomainSettingsEnabled: true )
190+ sessionManager. defaultSite = . fake( ) . copy ( isWordPressComStore: false )
191+ let viewModel = SettingsViewModel ( stores: stores,
192+ storageManager: storageManager,
193+ featureFlagService: featureFlagService,
194+ appleIDCredentialChecker: appleIDCredentialChecker)
195+
196+ // When
197+ viewModel. onViewDidLoad ( )
198+
199+ // Then
200+ XCTAssertFalse ( viewModel. sections. contains { $0. rows. contains ( SettingsViewController . Row. domain) } )
201+ }
202+
203+ func test_domain_is_shown_when_domainSettings_feature_is_enabled_and_site_is_wpcom( ) {
188204 // Given
189205 let featureFlagService = MockFeatureFlagService ( isDomainSettingsEnabled: true )
190206 sessionManager. defaultSite = . fake( ) . copy ( isWordPressComStore: true )
You can’t perform that action at this time.
0 commit comments