I've done something in build.gradle to remove the green highlighting of the androidTest.java package.
I don't know how to get it back.
IntelliJ has a "Mark directory as test sources root" option in the context menu but I can't find the equivalent in Android Studio.
Is there a way to define this folder so I can start testing? (If it means anything, the test java files all have an icon of a "J" with a red circle around it)
Right click on src folder and select create directory and android studio will show you folder like "test/java", "test/kotlin", "androidTest/java" etc. Just select one, simple.
You can click on the folder and type Cmd + Shift + a
to enter the action search and then by typing Mark directory as
you will get the menu.
For me, this option is no longer so easily available. To access it I need to double tap 'shift' and manually type "mark directory as. Then I can pick it from the list."
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With