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

Commit bd93b86b authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Deduplicate test expectation data in a different way" into udc-dev am:...

Merge "Deduplicate test expectation data in a different way" into udc-dev am: 15988e77 am: 97796ab9

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/23824651



Change-Id: Ie0643fcdfb0281df5204d7dc2e4665c57055ea46
Signed-off-by: default avatarAutomerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
parents 855882a6 97796ab9
Loading
Loading
Loading
Loading
+4 −1
Original line number Original line Diff line number Diff line
@@ -61,8 +61,11 @@ public final class BinaryTransparencyHostTest extends BaseHostJUnit4Test {
        options.setTestMethodName("testCollectAllApexInfo");
        options.setTestMethodName("testCollectAllApexInfo");


        // Collect APEX package names from /apex, then pass them as expectation to be verified.
        // Collect APEX package names from /apex, then pass them as expectation to be verified.
        // The package names are collected from the find name with deduplication (NB: we used to
        // deduplicate by dropping directory names with '@', but there's a DCLA case where it only
        // has one directory with '@'. So we have to keep it and deduplicate the current way).
        CommandResult result = getDevice().executeShellV2Command(
        CommandResult result = getDevice().executeShellV2Command(
                "ls -d /apex/*/ |grep -v @ |grep -v /apex/sharedlibs |cut -d/ -f3");
                "ls -d /apex/*/ |grep -v /apex/sharedlibs |cut -d/ -f3 |cut -d@ -f1 |sort |uniq");
        assertTrue(result.getStatus() == CommandStatus.SUCCESS);
        assertTrue(result.getStatus() == CommandStatus.SUCCESS);
        String[] packageNames = result.getStdout().split("\n");
        String[] packageNames = result.getStdout().split("\n");
        for (var i = 0; i < packageNames.length; i++) {
        for (var i = 0; i < packageNames.length; i++) {