-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
module resources issue in 0.5.0.1 #2
Comments
Can I ask why did you closed the issue? |
It was a mistake. Reopened. |
The issues involves 2 parts.
|
Just to clarify. So it seems that source of my issue is that robolectric started with ElectricSpock is not configured based on this file. |
After further investigation it seems that when in android studio i use home directory as Further tracking point out also that robolectric.properties file is also not used the same as @config annotation. |
ok. sorry for the inconvenience. it works properly previously i had this file in resources deeper prefixed with my package name this was NOT working Now it is up to you what to do with @config. The source of the issue do not exist in ElectricSpock in my opinion or can be configured as i realized. |
Version 0.6 should work with @config properly. |
Hello. I switched to ElectricSpecification from RopoSpecification(Robospock) since i have robolectric 3.3.1 and your impl seems to be working with this robolectric version.
I will note that i have a robolectric working in modules of application.
It basically setup but i have problem accessing resources
i have basically such test that is in module (not app)
@config(manifest='src/main/AndroidManifest.xml')
class ExampleRoboSpec extends ElectricSpecification {
}
now whatever i put to manifest config i still get issue/warning:
WARNING: No manifest file found at ./AndroidManifest.xml.
Falling back to the Android OS resources only.
To remove this warning, annotate your test class with @config(manifest=Config.NONE).
what finally ends up with:
android.content.res.Resources$NotFoundException: Unable to find resource ID #0x7f060080 in packages [android, org.robolectric.default]
It seems that @config annotation (org.robolectric.annotation.Config) is not respected at all.
I have also a default working robolectric with robolectric.properties file but this is also not used
Question is how to get it working in general (module or app) since i tried both with still same above warning and resources missing
The text was updated successfully, but these errors were encountered: