summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPete Bentley <prb@google.com>2022-04-08 11:16:38 +0000
committerAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>2022-04-08 11:16:38 +0000
commit187f63cabe7da2da65656853ea19f68093f03941 (patch)
tree908f5aada3dc64d5ac5a4b71e0de8958a22854de
parenteb423afe6c3c205d6e5d61e229aca29f21c160ef (diff)
parent0c926c75f2803c266682402b20f6bd3097df5edd (diff)
downloadboringssl-187f63cabe7da2da65656853ea19f68093f03941.tar.gz
Add BoringSSL native tests to mts-conscrypt. am: fe406ed0f9 am: 039c2fa344 am: 0c926c75f2
Original change: https://android-review.googlesource.com/c/platform/external/boringssl/+/1749846 Change-Id: I50a559f417648f9b76d2d2b8c66f81a3acf31f9d Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
-rw-r--r--Android.bp39
-rw-r--r--NativeTests.xml40
2 files changed, 74 insertions, 5 deletions
diff --git a/Android.bp b/Android.bp
index ea7a7bdf..daec62ce 100644
--- a/Android.bp
+++ b/Android.bp
@@ -493,21 +493,45 @@ cc_library_static {
// Tests
cc_test {
name: "boringssl_crypto_test",
- test_suites: ["device-tests"],
- host_supported: true,
+ test_config: "NativeTests.xml",
+ host_supported: false,
+ per_testcase_directory: true,
+ compile_multilib: "both",
+ multilib: {
+ lib32: {
+ suffix: "32",
+ },
+ lib64: {
+ suffix: "64",
+ },
+ },
defaults: [
"boringssl_crypto_test_sources",
"boringssl_flags",
],
whole_static_libs: ["boringssl_test_support"],
-
shared_libs: ["libcrypto"],
+ target: {
+ android: {
+ test_suites: ["mts-conscrypt"],
+ },
+ },
}
cc_test {
name: "boringssl_ssl_test",
- test_suites: ["device-tests"],
- host_supported: true,
+ test_config: "NativeTests.xml",
+ host_supported: false,
+ per_testcase_directory: true,
+ compile_multilib: "both",
+ multilib: {
+ lib32: {
+ suffix: "32",
+ },
+ lib64: {
+ suffix: "64",
+ },
+ },
defaults: [
"boringssl_ssl_test_sources",
"boringssl_flags",
@@ -518,6 +542,11 @@ cc_test {
"libcrypto",
"libssl",
],
+ target: {
+ android: {
+ test_suites: ["mts-conscrypt"],
+ },
+ },
}
// Utility binary for CMVP on-site testing.
diff --git a/NativeTests.xml b/NativeTests.xml
new file mode 100644
index 00000000..d3eb9444
--- /dev/null
+++ b/NativeTests.xml
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2022 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ ~
+ ~ Re-runs a subset of MtsConscryptTestCases using Conscrypt's file-descriptor based
+ ~ implementation to ensure there are no regressions in this implementation before
+ ~ it is fully deprecated.
+ ~
+ ~ Apart from the include filters and SSLSocket implementation this test suite is
+ ~ identical to MtsConscryptTestCases.
+ -->
+<configuration description="Configuration for BoringSSL native tests">
+ <option name="test-suite-tag" value="mts-conscrypt" />
+ <target_preparer class="com.android.compatibility.common.tradefed.targetprep.FilePusher">
+ <option name="cleanup" value="true" />
+ <option name="push" value="boringssl_crypto_test->/data/local/tmp/boringssl_crypto_test" />
+ <option name="push" value="boringssl_ssl_test->/data/local/tmp/boringssl_ssl_test" />
+ <option name="append-bitness" value="true" />
+ </target_preparer>
+ <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer"/>
+ <test class="com.android.tradefed.testtype.GTest" >
+ <option name="native-test-device-path" value="/data/local/tmp" />
+ <option name="module-name" value="boringssl_crypto_test" />
+ <option name="module-name" value="boringssl_ssl_test" />
+ <option name="runtime-hint" value="10m" />
+ <option name="native-test-timeout" value="600000" />
+ </test>
+</configuration>