-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
NPE when creating visible Activities in @BeforeClass #1232
Comments
I have the same issue. Did you resolve this problem? |
I think I just moved it into a |
I have the issue in which ActivityController object returns null. I am using below lines to create Activity @before method I am getting NPE and all my tests getting failed because of this which are passed before. I am uing Robolectric 2.3 |
Why use |
@erd This is what I am talking about. This issue is really old and there is no replies on how to duplicate or if the issue still exists. Can we just close this? This should be put in |
I am having this issue. my code:
|
Stack trace? On 24 November 2015 at 23:05, yamo21 notifications@github.com wrote:
|
|
I have the same issue with yamo21 when build the test by "gradlew test". |
activity = Robolectric.buildActivity(LoginActivity.class).create().visible().get();
gives an error when in a JUnit's
@BeforeClass
(see bottom for stacktrace);while
activity = Robolectric.buildActivity(LoginActivity.class).get();
(notice how
create()
andvisible()
are gone) doesn't throw an error.The text was updated successfully, but these errors were encountered: