Skip to content
This repository was archived by the owner on Feb 24, 2025. It is now read-only.

Commit a4f4eb0

Browse files
Alessandro/onboarding add to dock experiment setup (#3679)
Task/Issue URL: https://app.asana.com/0/1206329551987282/1208662187851716/f **Description**: This PR setup the Add to Dock experiment to be prompted from the onboarding flow.
1 parent b32409d commit a4f4eb0

File tree

59 files changed

+592
-1800
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+592
-1800
lines changed

.maestro/onboarding_tests/01_control_group_onboarding.yaml

-29
This file was deleted.

.maestro/onboarding_tests/03_experiment_group_linear_onboarding.yaml .maestro/onboarding_tests/01_onboarding_contextual.yaml

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ tags:
99
file: ../shared/setup.yaml
1010
env:
1111
ONBOARDING_COMPLETED: "false"
12-
APP_VARIANT: "mb"
12+
APP_VARIANT: "mh"
1313

1414
# Handle Search Suggestions
1515
- assertVisible: "Ready to get started?\nTry a search!"
@@ -50,3 +50,4 @@ tags:
5050
- assertVisible: "You’ve got this!"
5151
- assertVisible: "High five!"
5252
- tapOn: "High five!"
53+

.maestro/onboarding_tests/02_control_group_hide_onboarding.yaml

-33
This file was deleted.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
appId: com.duckduckgo.mobile.ios
2+
tags:
3+
- onboarding
4+
5+
---
6+
7+
# Set up
8+
- runFlow:
9+
file: ../shared/setup.yaml
10+
env:
11+
ONBOARDING_COMPLETED: "false"
12+
APP_VARIANT: "mk"
13+
14+
# Handle Search Suggestions
15+
- assertVisible: "Ready to get started?\nTry a search!"
16+
- assertVisible: "Surprise Me!"
17+
- tapOn: "Surprise Me!"
18+
19+
# Handle First Dax Dialog
20+
- assertVisible: "That’s DuckDuckGo Search. Private. Fast. Fewer ads."
21+
- assertVisible: "Got It!"
22+
- tapOn: "Got It!"
23+
24+
# Handle Site Suggestions
25+
- assertVisible: "Next, try visiting a site!"
26+
- assertVisible: "Surprise Me!"
27+
- tapOn: "Surprise Me!"
28+
29+
# Handle Privacy Dashboard
30+
- assertVisible: "Got It!"
31+
- tapOn:
32+
point: "6%,10%" # Shield icon.
33+
- assertVisible:
34+
text: "View Tracker Companies"
35+
- assertVisible:
36+
text: "Done"
37+
- tapOn: "Done"
38+
39+
# Handle Fire Message
40+
- assertVisible: "Got It!"
41+
- tapOn: "Got It!"
42+
- assertVisible: "Instantly clear your browsing activity with the Fire Button.\n\nGive it a try! 🔥"
43+
44+
# Handle Fire Button
45+
- assertVisible: "Close Tabs and Clear Data"
46+
- tapOn: "Close Tabs and Clear Data"
47+
- tapOn: "Close Tabs and Clear Data"
48+
49+
# Handle End of Journey Dialog
50+
- assertVisible: "You’ve got this!"
51+
- assertVisible: "High five!"
52+
- tapOn: "High five!"
53+
54+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
appId: com.duckduckgo.mobile.ios
2+
tags:
3+
- onboarding
4+
5+
---
6+
7+
# Set up
8+
- runFlow:
9+
file: ../shared/setup.yaml
10+
env:
11+
ONBOARDING_COMPLETED: "false"
12+
APP_VARIANT: "mo"
13+
14+
# Handle Search Suggestions
15+
- assertVisible: "Ready to get started?\nTry a search!"
16+
- assertVisible: "Surprise Me!"
17+
- tapOn: "Surprise Me!"
18+
19+
# Handle First Dax Dialog
20+
- assertVisible: "That’s DuckDuckGo Search. Private. Fast. Fewer ads."
21+
- assertVisible: "Got It!"
22+
- tapOn: "Got It!"
23+
24+
# Handle Site Suggestions
25+
- assertVisible: "Next, try visiting a site!"
26+
- assertVisible: "Surprise Me!"
27+
- tapOn: "Surprise Me!"
28+
29+
# Handle Privacy Dashboard
30+
- assertVisible: "Got It!"
31+
- tapOn:
32+
point: "6%,10%" # Shield icon.
33+
- assertVisible:
34+
text: "View Tracker Companies"
35+
- assertVisible:
36+
text: "Done"
37+
- tapOn: "Done"
38+
39+
# Handle Fire Message
40+
- assertVisible: "Got It!"
41+
- tapOn: "Got It!"
42+
- assertVisible: "Instantly clear your browsing activity with the Fire Button.\n\nGive it a try! 🔥"
43+
44+
# Handle Fire Button
45+
- assertVisible: "Close Tabs and Clear Data"
46+
- tapOn: "Close Tabs and Clear Data"
47+
- tapOn: "Close Tabs and Clear Data"
48+
49+
# Handle End of Journey Dialog
50+
- assertVisible: "Add me to your Dock!"
51+
- assertVisible: "Show Me How"
52+
- tapOn: "Start Browsing"
53+
54+

.maestro/shared/onboarding.yaml

+15-8
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,24 @@ appId: com.duckduckgo.mobile.ios
1010
text: "Let’s Do It!"
1111
index: 0
1212

13-
# Disabled while UI testing is happening
14-
# - assertVisible: "Make DuckDuckGo your default browser."
13+
# Browser comparison chart
14+
# - assertVisible: "Protections activated!"
1515
- tapOn:
1616
text: "Skip"
1717

18+
# Add To Dock Flow
1819
- runFlow:
1920
when:
20-
visible: "Which color looks best on me?"
21+
visible: "Add me to your Dock!"
2122
commands:
22-
- assertVisible: "Next"
23-
- tapOn: "Next"
24-
- assertVisible: "Where should I put your address bar?"
25-
- assertVisible: "Next"
26-
- tapOn: "Next"
23+
- assertVisible: "Show Me How"
24+
- tapOn: "Skip"
25+
26+
# Customization Flow
27+
28+
- assertVisible: "Which color looks best on me?"
29+
- assertVisible: "Next"
30+
- tapOn: "Next"
31+
- assertVisible: "Where should I put your address bar?"
32+
- assertVisible: "Next"
33+
- tapOn: "Next"

Core/DefaultVariantManager.swift

+5-6
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,8 @@ extension FeatureName {
2727
// Define your feature e.g.:
2828
// public static let experimentalFeature = FeatureName(rawValue: "experimentalFeature")
2929

30-
public static let newOnboardingIntro = FeatureName(rawValue: "newOnboardingIntro")
31-
public static let newOnboardingIntroHighlights = FeatureName(rawValue: "newOnboardingIntroHighlights")
32-
public static let contextualDaxDialogs = FeatureName(rawValue: "contextualDaxDialogs")
30+
public static let addToDockIntro = FeatureName(rawValue: "addToDockIntro")
31+
public static let addToDockContextual = FeatureName(rawValue: "addToDockContextual")
3332
}
3433

3534
public struct VariantIOS: Variant {
@@ -58,9 +57,9 @@ public struct VariantIOS: Variant {
5857
VariantIOS(name: "sd", weight: doNotAllocate, isIncluded: When.always, features: []),
5958
VariantIOS(name: "se", weight: doNotAllocate, isIncluded: When.always, features: []),
6059

61-
VariantIOS(name: "ms", weight: 1, isIncluded: When.always, features: [.newOnboardingIntro]),
62-
VariantIOS(name: "mu", weight: 1, isIncluded: When.always, features: [.newOnboardingIntro, .contextualDaxDialogs]),
63-
VariantIOS(name: "mx", weight: 1, isIncluded: When.always, features: [.newOnboardingIntroHighlights, .contextualDaxDialogs]),
60+
VariantIOS(name: "mh", weight: 1, isIncluded: When.notPadDevice, features: []),
61+
VariantIOS(name: "mk", weight: 1, isIncluded: When.notPadDevice, features: [.addToDockIntro]),
62+
VariantIOS(name: "mo", weight: 1, isIncluded: When.notPadDevice, features: [.addToDockContextual]),
6463

6564
returningUser
6665
]

DuckDuckGo.xcodeproj/project.pbxproj

-8
Original file line numberDiff line numberDiff line change
@@ -748,8 +748,6 @@
748748
98F3A1D8217B37010011A0D4 /* Theme.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F3A1D7217B37010011A0D4 /* Theme.swift */; };
749749
98F6EA472863124100720957 /* ContentBlockerRulesLists.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F6EA462863124100720957 /* ContentBlockerRulesLists.swift */; };
750750
98F78B8E22419093007CACF4 /* ThemableNavigationController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98F78B8D22419093007CACF4 /* ThemableNavigationController.swift */; };
751-
9F1061652C9C013F008DD5A0 /* DefaultVariantManager+Onboarding.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F1061642C9C013F008DD5A0 /* DefaultVariantManager+Onboarding.swift */; };
752-
9F1623092C9D14F10093C4FC /* DefaultVariantManagerOnboardingTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F1623082C9D14F10093C4FC /* DefaultVariantManagerOnboardingTests.swift */; };
753751
9F16230B2CA0F0190093C4FC /* DebouncerTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F16230A2CA0F0190093C4FC /* DebouncerTests.swift */; };
754752
9F1798572CD2443F0073018B /* AddToDockPromoViewModelTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F1798562CD2443F0073018B /* AddToDockPromoViewModelTests.swift */; };
755753
9F23B8012C2BC94400950875 /* OnboardingBackground.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9F23B8002C2BC94400950875 /* OnboardingBackground.swift */; };
@@ -2593,8 +2591,6 @@
25932591
98F3A1D7217B37010011A0D4 /* Theme.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Theme.swift; sourceTree = "<group>"; };
25942592
98F6EA462863124100720957 /* ContentBlockerRulesLists.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ContentBlockerRulesLists.swift; sourceTree = "<group>"; };
25952593
98F78B8D22419093007CACF4 /* ThemableNavigationController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ThemableNavigationController.swift; sourceTree = "<group>"; };
2596-
9F1061642C9C013F008DD5A0 /* DefaultVariantManager+Onboarding.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "DefaultVariantManager+Onboarding.swift"; sourceTree = "<group>"; };
2597-
9F1623082C9D14F10093C4FC /* DefaultVariantManagerOnboardingTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DefaultVariantManagerOnboardingTests.swift; sourceTree = "<group>"; };
25982594
9F16230A2CA0F0190093C4FC /* DebouncerTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = DebouncerTests.swift; sourceTree = "<group>"; };
25992595
9F1798562CD2443F0073018B /* AddToDockPromoViewModelTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AddToDockPromoViewModelTests.swift; sourceTree = "<group>"; };
26002596
9F23B8002C2BC94400950875 /* OnboardingBackground.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = OnboardingBackground.swift; sourceTree = "<group>"; };
@@ -4969,7 +4965,6 @@
49694965
9F7CFF7C2C89B69A0012833E /* AppIconPickerViewModelTests.swift */,
49704966
9FDEC7B32C8FD62F00C7A692 /* OnboardingAddressBarPositionPickerViewModelTests.swift */,
49714967
9FDEC7B92C9006E000C7A692 /* BrowserComparisonModelTests.swift */,
4972-
9F1623082C9D14F10093C4FC /* DefaultVariantManagerOnboardingTests.swift */,
49734968
9F8E0F322CCA642D001EA7C5 /* VideoPlayerViewModelTests.swift */,
49744969
9F1798562CD2443F0073018B /* AddToDockPromoViewModelTests.swift */,
49754970
);
@@ -5129,7 +5124,6 @@
51295124
9F23B7FF2C2BABE000950875 /* OnboardingIntro */,
51305125
9F5E5AAA2C3D0FAA00165F54 /* ContextualOnboarding */,
51315126
9FCFCD842C75C91A006EB7A0 /* ProgressBarView.swift */,
5132-
9F1061642C9C013F008DD5A0 /* DefaultVariantManager+Onboarding.swift */,
51335127
);
51345128
path = OnboardingExperiment;
51355129
sourceTree = "<group>";
@@ -7750,7 +7744,6 @@
77507744
6FBF0F8B2BD7C0A900136CF0 /* AllProtectedCell.swift in Sources */,
77517745
9F4CC5242C4A4F0D006A96EB /* SwiftUITestUtilities.swift in Sources */,
77527746
6FDC64032C92F4D600DB71B3 /* NewTabPageSettingsPersistentStore.swift in Sources */,
7753-
9F1061652C9C013F008DD5A0 /* DefaultVariantManager+Onboarding.swift in Sources */,
77547747
1E4F4A5A297193DE00625985 /* MainViewController+CookiesManaged.swift in Sources */,
77557748
C12324C32C4697C900FBB26B /* AutofillBreakageReportTableViewCell.swift in Sources */,
77567749
8586A10D24CBA7070049720E /* FindInPageActivity.swift in Sources */,
@@ -8292,7 +8285,6 @@
82928285
987130C7294AAB9F00AB05E0 /* MenuBookmarksViewModelTests.swift in Sources */,
82938286
D6B9E8D42CDA8375002B640C /* DuckPlayerOverlayUsagePixelsTests.swift in Sources */,
82948287
858650D32469BFAD00C36F8A /* DaxDialogTests.swift in Sources */,
8295-
9F1623092C9D14F10093C4FC /* DefaultVariantManagerOnboardingTests.swift in Sources */,
82968288
31C138B227A4097800FFD4B2 /* DownloadTestsHelper.swift in Sources */,
82978289
1E1D8B5D2994FFE100C96994 /* AutoconsentMessageProtocolTests.swift in Sources */,
82988290
85C11E532090B23A00BFFEB4 /* UserDefaultsHomeRowReminderStorageTests.swift in Sources */,

0 commit comments

Comments
 (0)