Skip to content

PermissionRequester throws java.lang.RuntimeException: Error while connecting UiAutomation on API < 28 #716

@PaulKlauser

Description

@PaulKlauser

Description

When using PermissionRequester in an instrumented test on API < 28, there's a RuntimeException that says "Error while connecting UiAutomation"

Steps to Reproduce

Create a custom test runner
Request permissions in either callApplicationOnCreate() or callActivityOnCreate() through PermissionRequester API
Run instrumented test on API < 28

Expected Results

Permission is granted and can be utilized

Actual Results

Test crashes before even starting

AndroidX Test and Android OS Versions

Test: 1.2.0
API < 28, tested down to 25

Link to a public git repo demonstrating the problem:

https://github.com/PaulKlauser/PermissionRequesterCrash

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