()
+ verify { connectivityManager.registerNetworkCallback(any(), capture(slot)) }
+ return slot.captured
+ }
+}
diff --git a/automation/taskcluster/androidTest/flank-x86-screenshots-tests.yml b/automation/taskcluster/androidTest/flank-x86-screenshots-tests.yml
new file mode 100644
index 000000000..61adceda5
--- /dev/null
+++ b/automation/taskcluster/androidTest/flank-x86-screenshots-tests.yml
@@ -0,0 +1,55 @@
+# gcloud args match the official gcloud cli
+# https://cloud.google.com/sdk/gcloud/reference/firebase/test/android/run
+gcloud:
+ results-bucket: fenix_test_artifacts
+ record-video: true
+
+ # The maximum possible testing time is 30m on physical devices and 60m on virtual devices.
+ timeout: 20m
+ # will start test then close socket. no reports will be generated.
+ # to retrieve results later, use the "refresh" command
+ # reports will be generated from /results/matrix_ids.json
+ #async: true
+ # will start test then leave socket open. reports will be published
+ # to /results
+ # see: https://github.com/TestArmada/flank/issues/339
+ async: false
+
+ # results-history-name
+ # by default, set to app name
+ # declare results-history-name to create a separate dropdown menu in Firebase
+ # see: https://github.com/TestArmada/flank/issues/341
+ #results-history-name: tmp_parallel
+
+ # The number of times a test execution should be re-attempted if one or more failures occur.
+ # The maximum number of reruns allowed is 10. Default is 0, which implies no reruns.
+ num-flaky-test-attempts: 1
+
+ # test and app are the only required args
+ app: /app/path
+ test: /test/path
+
+ auto-google-login: true
+ use-orchestrator: true
+ environment-variables:
+ clearPackageData: true
+ directories-to-pull:
+ - /sdcard/screenshots
+ performance-metrics: true
+
+ test-targets:
+ - package org.mozilla.fenix.screenshots
+
+ device:
+ - model: Pixel2
+ version: 28
+
+flank:
+ project: GOOGLE_PROJECT
+ # test shards - the amount of groups to split the test suite into
+ # set to -1 to use one shard per test.
+ max-test-shards: 1
+ # num-test-runs: the amount of times to run the tests.
+ # 1 runs the tests once. 10 runs all the tests 10x
+ num-test-runs: 1
+
diff --git a/automation/taskcluster/androidTest/ui-test.sh b/automation/taskcluster/androidTest/ui-test.sh
index 2b1812ea2..e45e9b8cc 100755
--- a/automation/taskcluster/androidTest/ui-test.sh
+++ b/automation/taskcluster/androidTest/ui-test.sh
@@ -80,6 +80,8 @@ elif [[ "${device_type}" == "x86-start-test" ]]; then
flank_template="${PATH_TEST}/flank-x86-start-test.yml"
elif [[ "${device_type}" == "arm-start-test" ]]; then
flank_template="${PATH_TEST}/flank-armeabi-v7a-start-test.yml"
+elif [[ "${device_type}" == "x86-screenshots-tests" ]]; then
+ flank_template="${PATH_TEST}/flank-x86-screenshots-tests.yml"
else
echo "FAILURE: flank config file not found!"
exitcode=1
diff --git a/buildSrc/src/main/java/AndroidComponents.kt b/buildSrc/src/main/java/AndroidComponents.kt
index 5cc71f95f..2968a13d6 100644
--- a/buildSrc/src/main/java/AndroidComponents.kt
+++ b/buildSrc/src/main/java/AndroidComponents.kt
@@ -3,5 +3,5 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
object AndroidComponents {
- const val VERSION = "50.0.20200712190143"
+ const val VERSION = "51.0.20200716130034"
}
diff --git a/buildSrc/src/main/java/Dependencies.kt b/buildSrc/src/main/java/Dependencies.kt
index 69f2d65e0..3c2ba184e 100644
--- a/buildSrc/src/main/java/Dependencies.kt
+++ b/buildSrc/src/main/java/Dependencies.kt
@@ -3,7 +3,7 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
object Versions {
- const val kotlin = "1.3.30"
+ const val kotlin = "1.3.72"
const val coroutines = "1.3.3"
const val android_gradle_plugin = "3.5.0"
const val sentry = "1.7.10"
diff --git a/docs/mma.md b/docs/mma.md
index 90f3d7a5c..1340ff105 100644
--- a/docs/mma.md
+++ b/docs/mma.md
@@ -144,6 +144,16 @@ User Attributes
A boolean indicating that the user has at least one search widget placed on the home screen |
#4694 |
+
+ `tracking_protection_enabled` |
+ A boolean indicating that the user has enabled tracking protection |
+ #11965 |
+
+
+ `tracking_protection_setting` |
+ A string indicating the level at which the user has set tracking protection. Possible values are `none`, `standard`, `strict` and `custom` |
+ #11965 |
+
`fenix` |
A boolean indicating that this is a Fenix installation |
@@ -254,6 +264,18 @@ Here is the list of current deep links available, which can be found here in the
`fenix://home` |
Opens to the Fenix home screen |
+
+ `fenix://urls_bookmarks` |
+ Opens to the list of the user's bookmarks at its root |
+
+
+ `fenix://urls_history` |
+ Opens to the list of pages the user has visited |
+
+
+ `fenix://home_collections` |
+ Opens to the list of collections the user has saved. It is implemented as `fenix://home` |
+
`fenix://settings` |
Opens to the top level settings screen |
@@ -274,6 +296,22 @@ Here is the list of current deep links available, which can be found here in the
`fenix://settings_delete_browsing_data` |
Opens to the delete browsing data settings screen |
+
+ `fenix://settings_addon_manager` |
+ Opens to the settings page to install and manage addons |
+
+
+ `fenix://settings_logins` |
+ Opens to the Logins and passwords settings page configure how logins are treated. This is *not* the list of actual logins |
+
+
+ `fenix://settings_tracking_protection` |
+ Opens to the Enhanced Tracking Protection settings page |
+
+
+ `fenix://settings_privacy` |
+ Opens to the settings page which contains the privacy settings. Currently, this is the same as `fenix://settings` |
+
`fenix://enable_private_browsing` |
Opens to the Fenix home screen and enables private browsing |
@@ -286,6 +324,14 @@ Here is the list of current deep links available, which can be found here in the
`fenix://make_default_browser` |
Opens to the Android default apps settings screen. **Only works on Android API >=24** |
+
+ `fenix://settings_notifications` |
+ Opens to the Android notification settings screen for Fenix. **Only works on Android API >=24** |
+
+
+ `fenix://install_search_widget` |
+ Adds the search widget to the users launcher homescreen. **Only works on Android API >=26** |
+
Messages
diff --git a/mozilla-lint-rules/src/main/java/org/mozilla/fenix/lintrules/ButtonStyleXmlDetector.kt b/mozilla-lint-rules/src/main/java/org/mozilla/fenix/lintrules/ButtonStyleXmlDetector.kt
index ceac3222d..c96f3a8e9 100644
--- a/mozilla-lint-rules/src/main/java/org/mozilla/fenix/lintrules/ButtonStyleXmlDetector.kt
+++ b/mozilla-lint-rules/src/main/java/org/mozilla/fenix/lintrules/ButtonStyleXmlDetector.kt
@@ -22,7 +22,6 @@ class ButtonStyleXmlDetector : ResourceXmlDetector() {
companion object {
const val SCHEMA = "http://schemas.android.com/apk/res-auto"
- // TODO:
const val ERROR_MESSAGE =
"All buttons must have a style, try using NeutralButton or similar."
diff --git a/taskcluster/ci/ui-test/kind.yml b/taskcluster/ci/ui-test/kind.yml
index 4426d8989..66665abb2 100644
--- a/taskcluster/ci/ui-test/kind.yml
+++ b/taskcluster/ci/ui-test/kind.yml
@@ -11,44 +11,56 @@ transforms:
job-defaults:
attributes:
+ build-type: debug
code-review: true
retrigger: true
+ dependencies:
+ signing: signing-debug
+ signing-android-test: signing-android-test-debug
+ include-pull-request-number: true
+ run:
+ commands:
+ - [wget, {artifact-reference: ''}, '-O', app.apk]
+ - [wget, {artifact-reference: ''}, '-O', android-test.apk]
+ secrets:
+ - name: project/mobile/fenix/firebase
+ key: firebaseToken
+ path: .firebase_token.json
+ json: true
+ using: run-commands
+ use-caches: false
+ treeherder:
+ kind: test
+ platform: 'ui-test/opt'
+ tier: 2
+ worker:
+ docker-image: {in-tree: ui-tests}
+ max-run-time: 7200
+ env:
+ GOOGLE_APPLICATION_CREDENTIALS: '.firebase_token.json'
+ GOOGLE_PROJECT: moz-fenix
+ artifacts:
+ - name: public
+ path: /builds/worker/artifacts
+ type: directory
+ worker-type: b-android
jobs:
x86-debug:
- attributes:
- build-type: debug
- dependencies:
- signing: signing-debug
- signing-android-test: signing-android-test-debug
description: Test Fenix
- include-pull-request-number: true
run-on-tasks-for: [github-pull-request, github-push]
run:
commands:
- - [wget, {artifact-reference: ''}, '-O', app.apk]
- - [wget, {artifact-reference: ''}, '-O', android-test.apk]
- [automation/taskcluster/androidTest/ui-test.sh, x86, app.apk, android-test.apk, '50']
- secrets:
- - name: project/mobile/fenix/firebase
- key: firebaseToken
- path: .firebase_token.json
- json: true
- using: run-commands
- use-caches: false
treeherder:
- kind: test
- platform: 'ui-test/opt'
symbol: debug(ui-test-x86)
- tier: 2
- worker:
- docker-image: {in-tree: ui-tests}
- max-run-time: 7200
- env:
- GOOGLE_APPLICATION_CREDENTIALS: '.firebase_token.json'
- GOOGLE_PROJECT: moz-fenix
- artifacts:
- - name: public
- path: /builds/worker/artifacts
- type: directory
- worker-type: b-android
+ screenshots-x86:
+ attributes:
+ screenshots: true
+ description: Run UI screenshots tests to keep them up to date
+ run-on-tasks-for: []
+ run:
+ commands:
+ - [automation/taskcluster/androidTest/ui-test.sh, x86-screenshots-tests, app.apk, android-test.apk, '-1']
+ treeherder:
+ symbol: debug(screenshots-x86)
diff --git a/taskcluster/fenix_taskgraph/target_tasks.py b/taskcluster/fenix_taskgraph/target_tasks.py
index 9694d1b38..66242ebff 100644
--- a/taskcluster/fenix_taskgraph/target_tasks.py
+++ b/taskcluster/fenix_taskgraph/target_tasks.py
@@ -73,3 +73,13 @@ def target_tasks_bump_android_components(full_task_graph, parameters, graph_conf
return task.attributes.get("bump-type", "") == "android-components"
return [l for l, t in full_task_graph.tasks.iteritems() if filter(t, parameters)]
+
+
+@_target_task("screenshots")
+def target_tasks_screnshots(full_task_graph, parameters, graph_config):
+ """Select the set of tasks required to generate screenshots on a real device."""
+
+ def filter(task, parameters):
+ return task.attributes.get("screenshots", False)
+
+ return [l for l, t in full_task_graph.tasks.iteritems() if filter(t, parameters)]