summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonald Braunstein <rbraunstein@google.com>2024-03-26 16:29:59 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2024-03-26 16:29:59 +0000
commit24a2580651d996d8b28a55b4e91648c290ccbba4 (patch)
treef4b2b93ef59418dd192d4933c8258f7e9658866a
parentcab0c542fa90ab6c530820c3d45c054b4170e657 (diff)
parentf74ed57e846fdc117e55c14231c6f31f6cedd6f8 (diff)
downloadbase-24a2580651d996d8b28a55b4e91648c290ccbba4.tar.gz
Merge "Migrate options in TEST_MAPPING -> Android.bp" into main
-rw-r--r--services/tests/servicestests/Android.bp86
-rw-r--r--services/tests/servicestests/src/com/android/server/contentcapture/TEST_MAPPING6
-rw-r--r--services/tests/servicestests/src/com/android/server/contentprotection/TEST_MAPPING6
-rw-r--r--services/tests/servicestests/src/com/android/server/location/contexthub/TEST_MAPPING6
-rw-r--r--services/tests/servicestests/src/com/android/server/om/TEST_MAPPING6
-rw-r--r--services/tests/servicestests/src/com/android/server/os/TEST_MAPPING6
-rw-r--r--services/tests/servicestests/src/com/android/server/pm/TEST_MAPPING22
-rw-r--r--services/tests/servicestests/src/com/android/server/recoverysystem/TEST_MAPPING6
8 files changed, 129 insertions, 15 deletions
diff --git a/services/tests/servicestests/Android.bp b/services/tests/servicestests/Android.bp
index fad8115be7e3..c333eb7eed46 100644
--- a/services/tests/servicestests/Android.bp
+++ b/services/tests/servicestests/Android.bp
@@ -255,3 +255,89 @@ java_genrule {
"done && " +
"$(location soong_zip) -o $(out) -C $(genDir)/res -D $(genDir)/res",
}
+
+FLAKY_AND_IGNORED = [
+ "androidx.test.filters.FlakyTest",
+ "org.junit.Ignore",
+]
+// Used by content protection TEST_MAPPING
+test_module_config {
+ name: "FrameworksServicesTests_contentprotection",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.contentprotection"],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+test_module_config {
+ name: "FrameworksServicesTests_om",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.om."],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+// Used by contexthub TEST_MAPPING
+test_module_config {
+ name: "FrameworksServicesTests_contexthub_presubmit",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.location.contexthub."],
+ // TODO(ron): are these right, does it run anything?
+ include_annotations: ["android.platform.test.annotations.Presubmit"],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+test_module_config {
+ name: "FrameworksServicesTests_contexthub_postsubmit",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.location.contexthub."],
+ // TODO(ron): are these right, does it run anything?
+ include_annotations: ["android.platform.test.annotations.Postsubmit"],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+// Used by contentcapture
+test_module_config {
+ name: "FrameworksServicesTests_contentcapture",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.contentcapture"],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+test_module_config {
+ name: "FrameworksServicesTests_recoverysystem",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.recoverysystem."],
+ exclude_annotations: ["androidx.test.filters.FlakyTest"],
+}
+
+// server pm TEST_MAPPING
+test_module_config {
+ name: "FrameworksServicesTests_pm_presubmit",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_annotations: ["android.platform.test.annotations.Presubmit"],
+ include_filters: ["com.android.server.pm."],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+test_module_config {
+ name: "FrameworksServicesTests_pm_postsubmit",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_annotations: ["android.platform.test.annotations.Postsubmit"],
+ include_filters: ["com.android.server.pm."],
+ exclude_annotations: FLAKY_AND_IGNORED,
+}
+
+// server os TEST_MAPPING
+test_module_config {
+ name: "FrameworksServicesTests_os",
+ base: "FrameworksServicesTests",
+ test_suites: ["general-tests"],
+ include_filters: ["com.android.server.os."],
+}
diff --git a/services/tests/servicestests/src/com/android/server/contentcapture/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/contentcapture/TEST_MAPPING
index 0ffa891ce3e1..dae8f932cb91 100644
--- a/services/tests/servicestests/src/com/android/server/contentcapture/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/contentcapture/TEST_MAPPING
@@ -14,5 +14,11 @@
}
]
}
+ ],
+ "postsubmit": [
+ {
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_contentcapture"
+ }
]
}
diff --git a/services/tests/servicestests/src/com/android/server/contentprotection/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/contentprotection/TEST_MAPPING
index 419508ca5e17..32729a899a96 100644
--- a/services/tests/servicestests/src/com/android/server/contentprotection/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/contentprotection/TEST_MAPPING
@@ -14,5 +14,11 @@
}
]
}
+ ],
+ "postsubmit": [
+ {
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_contentprotection"
+ }
]
}
diff --git a/services/tests/servicestests/src/com/android/server/location/contexthub/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/location/contexthub/TEST_MAPPING
index 6035250500ec..dc8f934ff9e5 100644
--- a/services/tests/servicestests/src/com/android/server/location/contexthub/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/location/contexthub/TEST_MAPPING
@@ -20,12 +20,18 @@
],
"postsubmit": [
{
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_contexthub_presubmit"
+ },
+ {
"name": "FrameworksServicesTests",
"options": [
{
"include-filter": "com.android.server.location.contexthub."
},
{
+ // I believe this include annotation is preventing tests from being run
+ // as there are no matching tests with the Postsubmit annotation.
"include-annotation": "android.platform.test.annotations.Postsubmit"
},
{
diff --git a/services/tests/servicestests/src/com/android/server/om/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/om/TEST_MAPPING
index 558e2591161c..41c4383a0bec 100644
--- a/services/tests/servicestests/src/com/android/server/om/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/om/TEST_MAPPING
@@ -16,5 +16,11 @@
}
]
}
+ ],
+ "postsubmit": [
+ {
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_om"
+ }
]
}
diff --git a/services/tests/servicestests/src/com/android/server/os/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/os/TEST_MAPPING
index 5a46f8c4beea..06e7002924a7 100644
--- a/services/tests/servicestests/src/com/android/server/os/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/os/TEST_MAPPING
@@ -8,5 +8,11 @@
}
]
}
+ ],
+ "postsubmit": [
+ {
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_os"
+ }
]
}
diff --git a/services/tests/servicestests/src/com/android/server/pm/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/pm/TEST_MAPPING
index 85a73bb22009..f4e724f493c5 100644
--- a/services/tests/servicestests/src/com/android/server/pm/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/pm/TEST_MAPPING
@@ -20,21 +20,13 @@
],
"postsubmit": [
{
- "name": "FrameworksServicesTests",
- "options": [
- {
- "include-filter": "com.android.server.pm."
- },
- {
- "include-annotation": "android.platform.test.annotations.Postsubmit"
- },
- {
- "exclude-annotation": "androidx.test.filters.FlakyTest"
- },
- {
- "exclude-annotation": "org.junit.Ignore"
- }
- ]
+ // Presubmit is intentional here while testing with SLO checker.
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_pm_presubmit"
+ },
+ {
+ // Leave postsubmit here when migrating
+ "name": "FrameworksServicesTests_pm_postsubmit"
}
]
}
diff --git a/services/tests/servicestests/src/com/android/server/recoverysystem/TEST_MAPPING b/services/tests/servicestests/src/com/android/server/recoverysystem/TEST_MAPPING
index e9d8b2e709e7..7e7393c3a822 100644
--- a/services/tests/servicestests/src/com/android/server/recoverysystem/TEST_MAPPING
+++ b/services/tests/servicestests/src/com/android/server/recoverysystem/TEST_MAPPING
@@ -11,5 +11,11 @@
}
]
}
+ ],
+ "postsubmit": [
+ {
+ // b/331020193, Move to presubmit early april 2024
+ "name": "FrameworksServicesTests_recoverysystem"
+ }
]
} \ No newline at end of file