From b23cddfa052040267d560c5a86319bb2ed20b668 Mon Sep 17 00:00:00 2001 From: Konstantin Aksenov Date: Tue, 11 Jul 2023 10:52:23 +1000 Subject: [PATCH] feat(ci): fix ui tests for firebase --- ...ple-connected-checks.yml => pr-checks.yml} | 2 +- .../kakaocup/sample/TestActivityTest.kt | 18 -- .../main/res/layout/activity_alert_dialog.xml | 5 + sample/src/main/res/layout/activity_test.xml | 205 +++++++++--------- 4 files changed, 109 insertions(+), 121 deletions(-) rename .github/workflows/{pr-sample-connected-checks.yml => pr-checks.yml} (97%) diff --git a/.github/workflows/pr-sample-connected-checks.yml b/.github/workflows/pr-checks.yml similarity index 97% rename from .github/workflows/pr-sample-connected-checks.yml rename to .github/workflows/pr-checks.yml index 94b34b475..84c454bcb 100644 --- a/.github/workflows/pr-sample-connected-checks.yml +++ b/.github/workflows/pr-checks.yml @@ -57,7 +57,7 @@ jobs: strategy: fail-fast: false matrix: - api: [ 26, 27, 28, 29, 30, 32, 33 ] + api: [ 26, 27, 28, 29, 30, 31, 32, 33 ] steps: - uses: actions/checkout@v1 - name: Download APKs diff --git a/sample/src/androidTest/kotlin/io/github/kakaocup/sample/TestActivityTest.kt b/sample/src/androidTest/kotlin/io/github/kakaocup/sample/TestActivityTest.kt index abf46b3c4..916aa07aa 100644 --- a/sample/src/androidTest/kotlin/io/github/kakaocup/sample/TestActivityTest.kt +++ b/sample/src/androidTest/kotlin/io/github/kakaocup/sample/TestActivityTest.kt @@ -31,7 +31,6 @@ class TestActivityTest { } textViewLarge { - scrollTo() click() isVisible() hasText("LARGE") @@ -41,7 +40,6 @@ class TestActivityTest { } textViewSmall { - scrollTo() isVisible() hasText("small") isCompletelyBelow { @@ -50,13 +48,11 @@ class TestActivityTest { } textViewHint { - scrollTo() isVisible() hasHint("hint") } buttonViewLeft { - scrollTo() isVisible() hasText("left") isCompletelyLeftOf { @@ -65,7 +61,6 @@ class TestActivityTest { } buttonViewRight { - scrollTo() isVisible() hasText("right") isCompletelyRightOf { @@ -74,7 +69,6 @@ class TestActivityTest { } textViewSmall { - scrollTo() isVisible() hasText("small") isCompletelyBelow { @@ -83,46 +77,38 @@ class TestActivityTest { } textViewColored { - scrollTo() hasTextColor(R.color.background_color) } map { - scrollTo() click() hasAnyTag("test_tag", "non_test_tag") } multiTypeRecycler { - scrollTo() hasText("MULTI TYPE RECYCLER") } singleTypeRecycler { - scrollTo() hasText("SINGLE TYPE RECYCLER") } autoComplete { - scrollTo() hasText("AUTO_COMPLETE") } ratingbar { - scrollTo() hasRating(0f) setRatingAt(3f) hasRating(3f) } snackbarButton { - scrollTo() click() } snackbar { isDisplayed() - text { hasText("This is snackbar!") } action { hasText("DISMISS") @@ -134,14 +120,12 @@ class TestActivityTest { } seekbar { - scrollTo() hasProgress(70) dragProgressTo(30) hasProgress(30) } switch { - scrollTo() isChecked() click() isNotChecked() @@ -156,7 +140,6 @@ class TestActivityTest { } switchCompat { - scrollTo() isChecked() click() isNotChecked() @@ -175,7 +158,6 @@ class TestActivityTest { } searchView { - scrollTo() hasHint("This is the HINT!") hasHint(R.string.hint) typeQuery("Hello") diff --git a/sample/src/main/res/layout/activity_alert_dialog.xml b/sample/src/main/res/layout/activity_alert_dialog.xml index 2576032fa..297f12524 100644 --- a/sample/src/main/res/layout/activity_alert_dialog.xml +++ b/sample/src/main/res/layout/activity_alert_dialog.xml @@ -4,6 +4,11 @@ android:layout_height="match_parent" android:orientation="vertical"> + + +