Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a42c9483 authored by Remi NGUYEN VAN's avatar Remi NGUYEN VAN
Browse files

Set min_sdk to 29 for NetworkStack tests

This allows installing the test package and running it on a release
build device even if the test is built from a branch with a
in-development or newer SDK.
The tests may still fail once run, but this approach allows excluding
specific tests if they use newer SDK features instead of blocking the
whole test suite at install time.

Bug: 145183152
Test: atest NetworkStackTests NetworkStackIntegrationTests
      NetworkStackTests still doesn't pass against qt-release but at
      least the tests are runnable.

Change-Id: Ie0ca963e2771ef317db9176cad8ce2b1b73567a7
parent 568c32fe
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -17,6 +17,7 @@
android_test {
    name: "NetworkStackIntegrationTests",
    certificate: "networkstack",
    min_sdk_version: "29",
    srcs: ["src/**/*.java"],
    test_suites: ["device-tests"],
    static_libs: [
+1 −0
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="com.android.server.networkstack.integrationtests"
          android:sharedUserId="android.uid.networkstack">
    <uses-sdk android:minSdkVersion="29" android:targetSdkVersion="29" />

    <!-- Note: do not add any privileged or signature permissions that are granted
         to the network stack app. Otherwise, the test APK will install, but when the device is
+1 −0
Original line number Diff line number Diff line
@@ -50,6 +50,7 @@ android_test {

android_test {
    name: "NetworkStackTests",
    min_sdk_version: "29",
    test_suites: ["device-tests"],
    defaults: ["NetworkStackTestsDefaults"],
    static_libs: ["NetworkStackApiStableLib"],
+1 −0
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@
-->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          package="com.android.server.networkstack.tests">
    <uses-sdk android:minSdkVersion="29" android:targetSdkVersion="29" />

    <uses-permission android:name="android.permission.READ_LOGS" />
    <uses-permission android:name="android.permission.WRITE_SETTINGS" />