'When building gradle in terminal, assemble succeeds but connectedAndroidTest fails
There is an Android project currently under maintenance.
Run the build directly from Android Studio. It succeeds and works as expected.
Run Instrumented Test directly from AndroidStudio. It succeeds and works as expected.
Execute the build through the following command in the terminal.
./gradlew assembleMyFlavorVariantDebug
It succeeds and works as expected.
- Execute Instrumented Test through the following command in the terminal.
./gradlew connectedMyFlavorVariantDebugAndroidTest
The build fails, and the following error log is output.
ERROR:/Users/(user)...../my_layout.xml : resource string/my_string not found.
The assemble succeeds, but can the connectedAndroidTest fail due to a problem with the main resource link?
Before I run connectedAndroidTest
I tried to utilize the cached result by running ./gradlew clean and assemble beforehand, but the same error is occurring in both.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
