Skip to content

Suggestion on Rerun Tests Documentation #8771

Open
@grndvl1

Description

@grndvl1

jekyll/_cci2/rerun-failed-tests.adoc

Here in the documentation there is no example of how to rerun a failed test with CI and using Android or iOS builds.

Typically you'll see something like this for android a gradle command to run the UI tests that are annotated with @regression. Then because of sharding and using a gradle managed phone device the tests and data relevant are in multiple directories. These are copied into one and stored for reading and acting on the xml results with another action/CI job

    steps:
      - run:
          name: Android Test - App module (Regression/No fail)
          command: ./gradlew app:phonesGroupDebugAndroidTest -Pandroid.testInstrumentationRunnerArguments.annotation=com.android.annotation.Regression -info || true

      - run:
          name: Finding Artifacts
          command: |
            mkdir -p ~/test-results/junit/ \;
            mkdir -p ~/test-results/ui-tests/ \;
            mkdir -p ~/test-results/ui-tests/html/ \;
            mkdir -p ~/test-results/ui-tests/html/css \;
            mkdir -p ~/test-results/ui-tests/html/js \;
            find . -type f -regex ".*/build/outputs/androidTest-results/managedDevice/debug/*/*.*" -exec cp {} ~/test-results/ui-tests/ \;
            find . -type f -regex ".*/build/reports/androidTests/managedDevice/debug/allDevices/*.*" -exec cp {} ~/test-results/ui-tests/html/ \;
            find . -type f -regex ".*/build/reports/androidTests/managedDevice/debug/allDevices/css/*.*" -exec cp {} ~/test-results/ui-tests/html/css/ \;
            find . -type f -regex ".*/build/reports/androidTests/managedDevice/debug/allDevices/js/*.*" -exec cp {} ~/test-results/ui-tests/html/js/ \;
          when: always

      - store_test_results:
          path: ~/test-results

      - store_artifacts:
          path: ~/test-results/ui-tests

I don't see how the rerun tests will work for Android or iOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions