When I try to run Android tests by doing:
./gradlew connectedDebugAndroidTest
The following error has occurred:
com.android.builder.testing.ConnectedDevice > No tests found.[devicename] FAILED
No tests found. This usually means that your test classes are not in the form that your test runner expects (e.g. don't inherit from TestCase or lack @Test annotations).
:connectedDebugAndroidTest FAILED
FAILURE: Build failed with an exception.
I did not make any changes to the files build.gradleor gradle-wrapper.properties.
The problem cannot be solved by updating everything to the latest version (gradle, android plugin, build tools, etc.)
All tests have been successful previously. What can cause this mystical regression? Thank.
source
share