From b85d6f1ad4bd914088c8ea760640d1fcc02a7f36 Mon Sep 17 00:00:00 2001 From: Pablo Gamito Date: Tue, 8 Feb 2022 17:09:17 +0100 Subject: [PATCH] Remove fass assertions from tests Assertions are very flaky, don't provide any immediately useful information in the current state and going to be replace soon anyways Test: atest FlickerTests Change-Id: Id8f7649b818237bc16051d808ef46ca875669faa --- .../wm/shell/flicker/pip/EnterPipTest.kt | 18 ---------------- .../shell/flicker/pip/ExitPipViaIntentTest.kt | 18 ---------------- .../pip/ExitPipWithDismissButtonTest.kt | 20 +----------------- .../wm/flicker/close/CloseAppTransition.kt | 21 +------------------ .../flicker/rotation/ChangeAppRotationTest.kt | 20 +----------------- 5 files changed, 3 insertions(+), 94 deletions(-) diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt index db94de238a5db..52f66372a4481 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/EnterPipTest.kt @@ -71,24 +71,6 @@ class EnterPipTest(testSpec: FlickerTestParameter) : PipTransition(testSpec) { } } - @FlakyTest - @Test - fun runPresubmitAssertion() { - flickerRule.checkPresubmitAssertions() - } - - @FlakyTest - @Test - fun runPostsubmitAssertion() { - flickerRule.checkPostsubmitAssertions() - } - - @FlakyTest - @Test - fun runFlakyAssertion() { - flickerRule.checkFlakyAssertions() - } - /** {@inheritDoc} */ @FlakyTest(bugId = 206753786) @Test diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipViaIntentTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipViaIntentTest.kt index 03c8929f99199..13af9eebb33aa 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipViaIntentTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipViaIntentTest.kt @@ -78,24 +78,6 @@ class ExitPipViaIntentTest(testSpec: FlickerTestParameter) : ExitPipToAppTransit } } - @FlakyTest - @Test - fun runPresubmitAssertion() { - flickerRule.checkPresubmitAssertions() - } - - @FlakyTest - @Test - fun runPostsubmitAssertion() { - flickerRule.checkPostsubmitAssertions() - } - - @FlakyTest - @Test - fun runFlakyAssertion() { - flickerRule.checkFlakyAssertions() - } - /** {@inheritDoc} */ @FlakyTest(bugId = 206753786) @Test diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipWithDismissButtonTest.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipWithDismissButtonTest.kt index 976b7c6980a1e..8ed5fc8dcad63 100644 --- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipWithDismissButtonTest.kt +++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/ExitPipWithDismissButtonTest.kt @@ -67,24 +67,6 @@ class ExitPipWithDismissButtonTest(testSpec: FlickerTestParameter) : ExitPipTran } } - @FlakyTest - @Test - fun runPresubmitAssertion() { - flickerRule.checkPresubmitAssertions() - } - - @FlakyTest - @Test - fun runPostsubmitAssertion() { - flickerRule.checkPostsubmitAssertions() - } - - @FlakyTest - @Test - fun runFlakyAssertion() { - flickerRule.checkFlakyAssertions() - } - /** {@inheritDoc} */ @FlakyTest(bugId = 206753786) @Test @@ -110,4 +92,4 @@ class ExitPipWithDismissButtonTest(testSpec: FlickerTestParameter) : ExitPipTran repetitions = 5) } } -} \ No newline at end of file +} diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppTransition.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppTransition.kt index ca73503164e6c..8d60466eff958 100644 --- a/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppTransition.kt +++ b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppTransition.kt @@ -18,7 +18,6 @@ package com.android.server.wm.flicker.close import android.app.Instrumentation import android.platform.test.annotations.Presubmit -import androidx.test.filters.FlakyTest import androidx.test.platform.app.InstrumentationRegistry import com.android.server.wm.flicker.FlickerBuilderProvider import com.android.server.wm.flicker.FlickerTestParameter @@ -194,22 +193,4 @@ abstract class CloseAppTransition(protected val testSpec: FlickerTestParameter) open fun launcherLayerReplacesApp() { testSpec.replacesLayer(testApp.component, LAUNCHER_COMPONENT) } - - @FlakyTest - @Test - fun runPresubmitAssertion() { - flickerRule.checkPresubmitAssertions() - } - - @FlakyTest - @Test - fun runPostsubmitAssertion() { - flickerRule.checkPostsubmitAssertions() - } - - @FlakyTest - @Test - fun runFlakyAssertion() { - flickerRule.checkFlakyAssertions() - } -} \ No newline at end of file +} diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/ChangeAppRotationTest.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/ChangeAppRotationTest.kt index 3f0de7f3cd7df..b4b69dc2059b1 100644 --- a/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/ChangeAppRotationTest.kt +++ b/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/ChangeAppRotationTest.kt @@ -94,24 +94,6 @@ class ChangeAppRotationTest( } } - @FlakyTest - @Test - fun runPresubmitAssertion() { - flickerRule.checkPresubmitAssertions() - } - - @FlakyTest - @Test - fun runPostsubmitAssertion() { - flickerRule.checkPostsubmitAssertions() - } - - @FlakyTest - @Test - fun runFlakyAssertion() { - flickerRule.checkFlakyAssertions() - } - /** * Windows maybe recreated when rotated. Checks that the focus does not change or if it does, * focus returns to [testApp] @@ -194,4 +176,4 @@ class ChangeAppRotationTest( .getConfigRotationTests(repetitions = 5) } } -} \ No newline at end of file +}