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

Commit 0606f92d authored by Nataniel Borges's avatar Nataniel Borges
Browse files

Print the checksum of the trace file on failure

When the flicker tests fail we log as well what is the checksum of the trace file which was analyzed to ensure that the file which was tested is the same available for debugging. Also, print the checksum information on the test failure message.

Test: atest FlickerTests, then check if the resulting folder contains a ".sha256" file for each WM/SF trace.
Change-Id: I448bf373e3b837c2e40317809d511a0f5236de1f
parent 7cacdf74
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -89,7 +89,7 @@ public class FlickerTestBase {
                        }
                        }
                        if (result.screenCaptureVideoExists()) {
                        if (result.screenCaptureVideoExists()) {
                            Log.e(TAG, "Screen capture video saved to " + result
                            Log.e(TAG, "Screen capture video saved to " + result
                                    .screenCaptureVideo.toString());
                                    .screenCaptureVideoPath().toString());
                        }
                        }
                    }
                    }
                });
                });
+2 −2
Original line number Original line Diff line number Diff line
@@ -95,7 +95,7 @@ public class ResizeSplitScreenTest extends NonRotationTestBase {
        Rect displayBounds = getDisplayBounds();
        Rect displayBounds = getDisplayBounds();
        checkResults(result -> {
        checkResults(result -> {
            LayersTrace entries = LayersTrace.parseFrom(result.getLayersTrace(),
            LayersTrace entries = LayersTrace.parseFrom(result.getLayersTrace(),
                    result.getLayersTracePath());
                    result.getLayersTracePath(), result.getLayersTraceChecksum());


            assertThat(entries.getEntries()).isNotEmpty();
            assertThat(entries.getEntries()).isNotEmpty();
            Rect startingDividerBounds = entries.getEntries().get(0).getVisibleBounds
            Rect startingDividerBounds = entries.getEntries().get(0).getVisibleBounds
@@ -124,7 +124,7 @@ public class ResizeSplitScreenTest extends NonRotationTestBase {
        Rect displayBounds = getDisplayBounds();
        Rect displayBounds = getDisplayBounds();
        checkResults(result -> {
        checkResults(result -> {
            LayersTrace entries = LayersTrace.parseFrom(result.getLayersTrace(),
            LayersTrace entries = LayersTrace.parseFrom(result.getLayersTrace(),
                    result.getLayersTracePath());
                    result.getLayersTracePath(), result.getLayersTraceChecksum());


            assertThat(entries.getEntries()).isNotEmpty();
            assertThat(entries.getEntries()).isNotEmpty();
            Rect endingDividerBounds = entries.getEntries().get(
            Rect endingDividerBounds = entries.getEntries().get(