diff --git a/.maestro/browser_features/opening_tabs.yaml b/.maestro/browser_features/opening_tabs.yaml index 0e81deca6c..da05abd5c0 100644 --- a/.maestro/browser_features/opening_tabs.yaml +++ b/.maestro/browser_features/opening_tabs.yaml @@ -43,8 +43,6 @@ tags: - tapOn: "Browse Back" - assertVisible: "A link that opens in a new window" -# Workaround - for some reason Tab Switcher button is not found by maestro at this point. -- tapOn: "Refresh Page" - runFlow: file: ../shared/check_number_of_tabs.yaml env: diff --git a/.maestro/security_tests/3_-_AddressBarSpoof,_appschemes.yaml b/.maestro/security_tests/3_-_AddressBarSpoof,_appschemes.yaml index 4080bbecba..4ff18ccc17 100644 --- a/.maestro/security_tests/3_-_AddressBarSpoof,_appschemes.yaml +++ b/.maestro/security_tests/3_-_AddressBarSpoof,_appschemes.yaml @@ -1,6 +1,6 @@ appId: com.duckduckgo.mobile.ios -tags: - - securityTest +#tags: +# - securityTest --- # Set up diff --git a/.maestro/shared/check_number_of_tabs.yaml b/.maestro/shared/check_number_of_tabs.yaml index 1ee4302570..63511f8883 100644 --- a/.maestro/shared/check_number_of_tabs.yaml +++ b/.maestro/shared/check_number_of_tabs.yaml @@ -1,6 +1,9 @@ appId: com.duckduckgo.mobile.ios --- +# Workaround - for some reason Tab Switcher button is not found by maestro at this point. +- tapOn: "Refresh Page" + - assertVisible: "Tab Switcher" - tapOn: "Tab Switcher" - assertVisible: ${TITLE} diff --git a/Core/FeatureFlag.swift b/Core/FeatureFlag.swift index 7ec10ba680..998f02a7a3 100644 --- a/Core/FeatureFlag.swift +++ b/Core/FeatureFlag.swift @@ -58,9 +58,6 @@ public enum FeatureFlag: String { /// https://app.asana.com/0/1208592102886666/1208613627589762/f case crashReportOptInStatusResetting - case isPrivacyProLaunchedROW - case isPrivacyProLaunchedROWOverride - /// https://app.asana.com/0/0/1208767141940869/f case freeTrials } @@ -71,8 +68,6 @@ extension FeatureFlag: FeatureFlagDescribing { public var supportsLocalOverriding: Bool { switch self { - case .isPrivacyProLaunchedROWOverride: - return true default: return false } @@ -140,10 +135,6 @@ extension FeatureFlag: FeatureFlagDescribing { return .remoteReleasable(.feature(.adAttributionReporting)) case .crashReportOptInStatusResetting: return .internalOnly() - case .isPrivacyProLaunchedROW: - return .remoteReleasable(.subfeature(PrivacyProSubfeature.isLaunchedROW)) - case .isPrivacyProLaunchedROWOverride: - return .remoteReleasable(.subfeature(PrivacyProSubfeature.isLaunchedROWOverride)) case .freeTrials: return .remoteDevelopment(.subfeature(PrivacyProSubfeature.freeTrials)) } diff --git a/DuckDuckGo.xcodeproj/project.pbxproj b/DuckDuckGo.xcodeproj/project.pbxproj index b9fd18769a..259e3992a9 100644 --- a/DuckDuckGo.xcodeproj/project.pbxproj +++ b/DuckDuckGo.xcodeproj/project.pbxproj @@ -9812,7 +9812,7 @@ CODE_SIGN_ENTITLEMENTS = PacketTunnelProvider/PacketTunnelProvider.entitlements; CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; GENERATE_INFOPLIST_FILE = YES; @@ -9849,7 +9849,7 @@ CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -9939,7 +9939,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = ShareExtension/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( @@ -9966,7 +9966,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -10114,7 +10114,7 @@ CODE_SIGN_ENTITLEMENTS = DuckDuckGo/DuckDuckGo.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEVELOPMENT_ASSET_PATHS = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; @@ -10140,7 +10140,7 @@ CODE_SIGN_ENTITLEMENTS = DuckDuckGo/DuckDuckGo.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; INFOPLIST_FILE = DuckDuckGo/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( @@ -10207,7 +10207,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEAD_CODE_STRIPPING = NO; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = Widgets/Info.plist; @@ -10241,7 +10241,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEAD_CODE_STRIPPING = NO; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; @@ -10274,7 +10274,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = OpenAction/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( @@ -10304,7 +10304,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -10635,7 +10635,7 @@ CODE_SIGN_ENTITLEMENTS = AutofillCredentialProvider/AutofillCredentialProvider.entitlements; CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = HKE973VLUW; ENABLE_USER_SCRIPT_SANDBOXING = YES; GCC_C_LANGUAGE_STANDARD = gnu17; @@ -10673,7 +10673,7 @@ CODE_SIGN_ENTITLEMENTS = AutofillCredentialProvider/AutofillCredentialProviderAlpha.entitlements; CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = HKE973VLUW; ENABLE_USER_SCRIPT_SANDBOXING = YES; GCC_C_LANGUAGE_STANDARD = gnu17; @@ -10710,7 +10710,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; ENABLE_USER_SCRIPT_SANDBOXING = YES; @@ -10749,7 +10749,7 @@ CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; ENABLE_USER_SCRIPT_SANDBOXING = YES; @@ -10847,7 +10847,7 @@ CODE_SIGN_ENTITLEMENTS = DuckDuckGo/DuckDuckGoAlpha.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEVELOPMENT_ASSET_PATHS = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; @@ -10878,7 +10878,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = ShareExtension/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( @@ -10906,7 +10906,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = OpenAction/Info.plist; LD_RUNPATH_SEARCH_PATHS = ( @@ -10939,7 +10939,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEAD_CODE_STRIPPING = NO; GCC_C_LANGUAGE_STANDARD = gnu11; INFOPLIST_FILE = Widgets/Info.plist; @@ -10969,7 +10969,7 @@ CODE_SIGN_ENTITLEMENTS = PacketTunnelProvider/PacketTunnelProviderAlpha.entitlements; CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; GENERATE_INFOPLIST_FILE = YES; @@ -11002,11 +11002,11 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 0; + DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Core/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; @@ -11238,7 +11238,7 @@ CODE_SIGN_ENTITLEMENTS = DuckDuckGo/DuckDuckGoAlpha.entitlements; CODE_SIGN_IDENTITY = "iPhone Distribution"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEVELOPMENT_ASSET_PATHS = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; @@ -11266,7 +11266,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -11298,7 +11298,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -11335,7 +11335,7 @@ CODE_SIGN_IDENTITY = "iPhone Developer"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEAD_CODE_STRIPPING = NO; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; @@ -11370,7 +11370,7 @@ CODE_SIGN_IDENTITY = "Apple Development"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution"; CODE_SIGN_STYLE = Manual; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEVELOPMENT_TEAM = ""; "DEVELOPMENT_TEAM[sdk=iphoneos*]" = HKE973VLUW; GCC_C_LANGUAGE_STANDARD = gnu11; @@ -11405,11 +11405,11 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 0; + DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Core/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; @@ -11581,11 +11581,11 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 0; + DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Core/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; @@ -11614,10 +11614,10 @@ CLANG_ENABLE_MODULES = YES; CODE_SIGN_IDENTITY = ""; CODE_SIGN_STYLE = Automatic; - CURRENT_PROJECT_VERSION = 0; + CURRENT_PROJECT_VERSION = 1; DEFINES_MODULE = YES; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 0; + DYLIB_CURRENT_VERSION = 1; DYLIB_INSTALL_NAME_BASE = "@rpath"; INFOPLIST_FILE = Core/Info.plist; INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks"; diff --git a/DuckDuckGo/AppDependencyProvider.swift b/DuckDuckGo/AppDependencyProvider.swift index 00b6f9fc29..387c3386bf 100644 --- a/DuckDuckGo/AppDependencyProvider.swift +++ b/DuckDuckGo/AppDependencyProvider.swift @@ -124,28 +124,14 @@ final class AppDependencyProvider: DependencyProvider { subscriptionEndpointService: subscriptionService, authEndpointService: authService) - let theFeatureFlagger = featureFlagger - let subscriptionFeatureFlagger: FeatureFlaggerMapping = FeatureFlaggerMapping { feature in - switch feature { - case .isLaunchedROW: - return theFeatureFlagger.isFeatureOn(.isPrivacyProLaunchedROW) - case .isLaunchedROWOverride: - return theFeatureFlagger.isFeatureOn(.isPrivacyProLaunchedROWOverride) - default: - return feature.defaultState - } - } - - let storePurchaseManager = DefaultStorePurchaseManager(subscriptionFeatureMappingCache: subscriptionFeatureMappingCache, - subscriptionFeatureFlagger: subscriptionFeatureFlagger) + let storePurchaseManager = DefaultStorePurchaseManager(subscriptionFeatureMappingCache: subscriptionFeatureMappingCache) let subscriptionManager = DefaultSubscriptionManager(storePurchaseManager: storePurchaseManager, accountManager: accountManager, subscriptionEndpointService: subscriptionService, authEndpointService: authService, subscriptionFeatureMappingCache: subscriptionFeatureMappingCache, - subscriptionEnvironment: subscriptionEnvironment, - subscriptionFeatureFlagger: subscriptionFeatureFlagger) + subscriptionEnvironment: subscriptionEnvironment) accountManager.delegate = subscriptionManager self.subscriptionManager = subscriptionManager diff --git a/DuckDuckGo/SettingsState.swift b/DuckDuckGo/SettingsState.swift index 2437693326..c4a4b8144b 100644 --- a/DuckDuckGo/SettingsState.swift +++ b/DuckDuckGo/SettingsState.swift @@ -37,7 +37,6 @@ struct SettingsState { } struct Subscription: Codable { - var enabled: Bool var canPurchase: Bool var isSignedIn: Bool var hasActiveSubscription: Bool @@ -136,8 +135,7 @@ struct SettingsState { speechRecognitionAvailable: false, loginsEnabled: false, networkProtectionConnected: false, - subscription: Subscription(enabled: false, - canPurchase: false, + subscription: Subscription(canPurchase: false, isSignedIn: false, hasActiveSubscription: false, isRestoring: false, diff --git a/DuckDuckGo/SettingsSubscriptionView.swift b/DuckDuckGo/SettingsSubscriptionView.swift index fdd097594b..d5e777ef44 100644 --- a/DuckDuckGo/SettingsSubscriptionView.swift +++ b/DuckDuckGo/SettingsSubscriptionView.swift @@ -272,7 +272,7 @@ struct SettingsSubscriptionView: View { } } .onReceive(settingsViewModel.$state) { state in - isShowingPrivacyPro = state.subscription.enabled && (state.subscription.isSignedIn || state.subscription.canPurchase) + isShowingPrivacyPro = (state.subscription.isSignedIn || state.subscription.canPurchase) } } } diff --git a/DuckDuckGo/SettingsViewModel.swift b/DuckDuckGo/SettingsViewModel.swift index 224f880c2c..a35de32255 100644 --- a/DuckDuckGo/SettingsViewModel.swift +++ b/DuckDuckGo/SettingsViewModel.swift @@ -757,9 +757,6 @@ extension SettingsViewModel { state.subscription = SettingsState.defaults.subscription } - // Update visibility based on Feature flag - state.subscription.enabled = subscriptionFeatureAvailability.isFeatureAvailable - // Update if can purchase based on App Store product availability state.subscription.canPurchase = subscriptionManager.canPurchase diff --git a/DuckDuckGo/SubscriptionDebugViewController.swift b/DuckDuckGo/SubscriptionDebugViewController.swift index 6dbc713030..ada4f33f33 100644 --- a/DuckDuckGo/SubscriptionDebugViewController.swift +++ b/DuckDuckGo/SubscriptionDebugViewController.swift @@ -44,8 +44,7 @@ final class SubscriptionDebugViewController: UITableViewController { Sections.appstore: "App Store", Sections.environment: "Environment", Sections.pixels: "Promo Pixel Parameters", - Sections.metadata: "StoreKit Metadata", - Sections.featureFlags: "Feature flags" + Sections.metadata: "StoreKit Metadata" ] enum Sections: Int, CaseIterable { @@ -55,7 +54,6 @@ final class SubscriptionDebugViewController: UITableViewController { case environment case pixels case metadata - case featureFlags } enum AuthorizationRows: Int, CaseIterable { @@ -88,10 +86,6 @@ final class SubscriptionDebugViewController: UITableViewController { case countryCode } - enum FeatureFlagRows: Int, CaseIterable { - case isLaunchedROW - } - private var storefrontID = "Loading" private var storefrontCountryCode = "Loading" @@ -184,15 +178,6 @@ final class SubscriptionDebugViewController: UITableViewController { break } - case .featureFlags: - switch FeatureFlagRows(rawValue: indexPath.row) { - case .isLaunchedROW: - cell.textLabel?.text = "isPrivacyProLaunchedROWOverride" - cell.accessoryType = featureFlagger.isFeatureOn(.isPrivacyProLaunchedROWOverride) ? .checkmark : .none - case .none: - break - } - case .none: break } @@ -208,7 +193,6 @@ final class SubscriptionDebugViewController: UITableViewController { case .environment: return EnvironmentRows.allCases.count case .pixels: return PixelsRows.allCases.count case .metadata: return MetadataRows.allCases.count - case .featureFlags: return FeatureFlagRows.allCases.count case .none: return 0 } } @@ -244,11 +228,6 @@ final class SubscriptionDebugViewController: UITableViewController { } case .metadata: break - case .featureFlags: - switch FeatureFlagRows(rawValue: indexPath.row) { - case .isLaunchedROW: toggleIsLaunchedROWFlag() - default: break - } case .none: break } @@ -357,16 +336,6 @@ final class SubscriptionDebugViewController: UITableViewController { showAlert(title: "", message: message) } - private func toggleIsLaunchedROWFlag() { - let flag = FeatureFlag.isPrivacyProLaunchedROWOverride - if featureFlagger.localOverrides?.override(for: flag) == nil { - featureFlagger.localOverrides?.toggleOverride(for: flag) - } else { - featureFlagger.localOverrides?.clearOverride(for: flag) - } - tableView.reloadData() - } - private func syncAppleIDAccount() { Task { do { diff --git a/DuckDuckGoTests/Subscription/SubscriptionFeatureAvailabilityMock.swift b/DuckDuckGoTests/Subscription/SubscriptionFeatureAvailabilityMock.swift index 055df663ca..f6095dbc9c 100644 --- a/DuckDuckGoTests/Subscription/SubscriptionFeatureAvailabilityMock.swift +++ b/DuckDuckGoTests/Subscription/SubscriptionFeatureAvailabilityMock.swift @@ -22,15 +22,13 @@ import Foundation public final class SubscriptionFeatureAvailabilityMock: SubscriptionFeatureAvailability { static var enabled: SubscriptionFeatureAvailabilityMock { - return SubscriptionFeatureAvailabilityMock(isFeatureAvailable: true, isSubscriptionPurchaseAllowed: true, usesUnifiedFeedbackForm: true) + return SubscriptionFeatureAvailabilityMock(isSubscriptionPurchaseAllowed: true, usesUnifiedFeedbackForm: true) } - public var isFeatureAvailable: Bool public var isSubscriptionPurchaseAllowed: Bool public var usesUnifiedFeedbackForm: Bool - public init(isFeatureAvailable: Bool, isSubscriptionPurchaseAllowed: Bool, usesUnifiedFeedbackForm: Bool) { - self.isFeatureAvailable = isFeatureAvailable + public init(isSubscriptionPurchaseAllowed: Bool, usesUnifiedFeedbackForm: Bool) { self.isSubscriptionPurchaseAllowed = isSubscriptionPurchaseAllowed self.usesUnifiedFeedbackForm = usesUnifiedFeedbackForm } diff --git a/DuckDuckGoTests/Subscription/SubscriptionPagesUseSubscriptionFeatureTests.swift b/DuckDuckGoTests/Subscription/SubscriptionPagesUseSubscriptionFeatureTests.swift index b350fbd2c6..434821cb4a 100644 --- a/DuckDuckGoTests/Subscription/SubscriptionPagesUseSubscriptionFeatureTests.swift +++ b/DuckDuckGoTests/Subscription/SubscriptionPagesUseSubscriptionFeatureTests.swift @@ -82,7 +82,6 @@ final class SubscriptionPagesUseSubscriptionFeatureTests: XCTestCase { var subscriptionEnvironment: SubscriptionEnvironment! var subscriptionFeatureMappingCache: SubscriptionFeatureMappingCacheMock! - var subscriptionFeatureFlagger: FeatureFlaggerMapping! var appStorePurchaseFlow: AppStorePurchaseFlow! var appStoreRestoreFlow: AppStoreRestoreFlow! @@ -134,7 +133,6 @@ final class SubscriptionPagesUseSubscriptionFeatureTests: XCTestCase { settings: UserDefaultsCacheSettings(defaultExpirationInterval: .minutes(20))) subscriptionFeatureMappingCache = SubscriptionFeatureMappingCacheMock() - subscriptionFeatureFlagger = FeatureFlaggerMapping(mapping: { $0.defaultState }) // Real AccountManager accountManager = DefaultAccountManager(storage: accountStorage, @@ -164,8 +162,7 @@ final class SubscriptionPagesUseSubscriptionFeatureTests: XCTestCase { subscriptionEndpointService: subscriptionService, authEndpointService: authService, subscriptionFeatureMappingCache: subscriptionFeatureMappingCache, - subscriptionEnvironment: subscriptionEnvironment, - subscriptionFeatureFlagger: subscriptionFeatureFlagger) + subscriptionEnvironment: subscriptionEnvironment) feature = SubscriptionPagesUseSubscriptionFeature(subscriptionManager: subscriptionManager, subscriptionFeatureAvailability: subscriptionFeatureAvailability, @@ -318,7 +315,6 @@ final class SubscriptionPagesUseSubscriptionFeatureTests: XCTestCase { func testGetSubscriptionOptionsReturnsEmptyOptionsWhenPurchaseNotAllowed() async throws { // Given let subscriptionFeatureAvailabilityWithoutPurchaseAllowed = SubscriptionFeatureAvailabilityMock( - isFeatureAvailable: true, isSubscriptionPurchaseAllowed: false, usesUnifiedFeedbackForm: true ) diff --git a/fastlane/README.md b/fastlane/README.md index bb3195509a..9ff34b6099 100644 --- a/fastlane/README.md +++ b/fastlane/README.md @@ -13,114 +13,116 @@ For _fastlane_ installation instructions, see [Installing _fastlane_](https://do # Available Actions -### sync_signing +## iOS + +### ios sync_signing ```sh -[bundle exec] fastlane sync_signing +[bundle exec] fastlane ios sync_signing ``` Fetches and updates certificates and provisioning profiles for App Store distribution -### sync_signing_adhoc +### ios sync_signing_adhoc ```sh -[bundle exec] fastlane sync_signing_adhoc +[bundle exec] fastlane ios sync_signing_adhoc ``` Fetches and updates certificates and provisioning profiles for Ad-Hoc distribution -### sync_signing_alpha +### ios sync_signing_alpha ```sh -[bundle exec] fastlane sync_signing_alpha +[bundle exec] fastlane ios sync_signing_alpha ``` Fetches and updates certificates and provisioning profiles for Alpha distribution -### sync_signing_alpha_adhoc +### ios sync_signing_alpha_adhoc ```sh -[bundle exec] fastlane sync_signing_alpha_adhoc +[bundle exec] fastlane ios sync_signing_alpha_adhoc ``` Fetches and updates certificates and provisioning profiles for Ad-Hoc distribution -### adhoc +### ios adhoc ```sh -[bundle exec] fastlane adhoc +[bundle exec] fastlane ios adhoc ``` Makes Ad-Hoc build with a specified name and alpha bundle ID in a given directory -### release_adhoc +### ios release_adhoc ```sh -[bundle exec] fastlane release_adhoc +[bundle exec] fastlane ios release_adhoc ``` Makes Ad-Hoc build with a specified name and release bundle ID in a given directory -### alpha_adhoc +### ios alpha_adhoc ```sh -[bundle exec] fastlane alpha_adhoc +[bundle exec] fastlane ios alpha_adhoc ``` Makes Ad-Hoc build for alpha with a specified name and alpha bundle ID in a given directory -### promote_latest_testflight_to_appstore +### ios promote_latest_testflight_to_appstore ```sh -[bundle exec] fastlane promote_latest_testflight_to_appstore +[bundle exec] fastlane ios promote_latest_testflight_to_appstore ``` Promotes the latest TestFlight build to App Store without submitting for review -### release_appstore +### ios release_appstore ```sh -[bundle exec] fastlane release_appstore +[bundle exec] fastlane ios release_appstore ``` Makes App Store release build and uploads it to App Store Connect -### upload_metadata +### ios upload_metadata ```sh -[bundle exec] fastlane upload_metadata +[bundle exec] fastlane ios upload_metadata ``` Updates App Store metadata -### release_testflight +### ios release_testflight ```sh -[bundle exec] fastlane release_testflight +[bundle exec] fastlane ios release_testflight ``` Makes App Store release build and uploads it to TestFlight -### release_alpha +### ios release_alpha ```sh -[bundle exec] fastlane release_alpha +[bundle exec] fastlane ios release_alpha ``` Makes Alpha release build and uploads it to TestFlight -### latest_build_number_for_version +### ios latest_build_number_for_version ```sh -[bundle exec] fastlane latest_build_number_for_version +[bundle exec] fastlane ios latest_build_number_for_version ``` Latest build number for version -### increment_build_number_for_version +### ios increment_build_number_for_version ```sh -[bundle exec] fastlane increment_build_number_for_version +[bundle exec] fastlane ios increment_build_number_for_version ``` Increment build number based on version in App Store Connect