Skip to content
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

Running Sample App Hangs Eclipse IDE #5

Closed
johnfrey99 opened this issue Mar 26, 2013 · 8 comments
Closed

Running Sample App Hangs Eclipse IDE #5

johnfrey99 opened this issue Mar 26, 2013 · 8 comments
Assignees
Milestone

Comments

@johnfrey99
Copy link

After importing the project into eclipse via "Import Existing Maven Projects" the sample app hangs eclipse when trying to run it with "Run as Android Application". The output in the console reports "Dx warning: Ignoring InnerClasses attribute for an anonymous inner class" and eventually Eclipse runs out of memory.

I'm not sure if this is an issue with your project per se so much as an issue with the maven eclipse plugin leaving test scoped dependencies in the android classpath at runtime. I remember seeing this issue before with maven projects using robolectric tests in the same project as the main app.

Would it be possible to separate out the robolectric tests into a separate maven module and still get unit test coverage reported via cobertura or jacoco? I did some experimenting with this but failed to get the coverage to work.

@ghost ghost assigned stephanenicolas Mar 30, 2013
@stephanenicolas
Copy link
Owner

Hi John,

the eclipse setup works really fine and I can't say where your error can come from.
The warning about inner classes is just a warning, nothing really important.

We use profiles to clearly separate compile and tests scoped dependencies so that eclipse doesn't mess all dependencies.

Nevertheless, I think you are right. I have been wondering about separating the robolectric tests in a different project. I find this to be less convenient but that would provide a better integration within eclipse.
The only problem I have with that is that this change would only be made to patch an eclipse / ADT deficiency. Everything already works pretty well on command line and in intelli J. I would really prefer to see eclipse moving in the right direction about this.

@stephanenicolas
Copy link
Owner

I plan this for next update. I am not sure whether eclipse integration is gonna get better any time soon.

@johnfrey99
Copy link
Author

Fantastic! I agree it looks like the issue in the eclipse integration has stalled and it's unfortunate that you should have to implement a workaround. I personally made the switch to IntelliJ a few months ago but there are still some members of my team who won't give up eclipse.

I really appreciate the fine work you have done on this project and you have saved me a huge amount of time figure these configurations out on my own. It also looks like you have made several nice contributions to the android maven plugin so thank you for that as well.

@stephanenicolas
Copy link
Owner

My pleasure John,

this project has been very interesting for us as well. We could explore a
lot of new technologies and try to combine them in a meaningful way.
All that's missing for us now is a better way to integrate all those tests
inside sonar or any other visualization alternative.

S.

2013/4/8 John Frey notifications@github.com

Fantastic! I agree it looks like the issue in the eclipse integration has
stalled and it's unfortunate that you should have to implement a
workaround. I personally made the switch to IntelliJ a few months ago but
there are still some members of my team who won't give up eclipse.

I really appreciate the fine work you have done on this project and you
have saved me a huge amount of time figure these configurations out on my
own. It also looks like you have made several nice contributions to the
android maven plugin so thank you for that as well.


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-16025855
.

Stéphane NICOLAS,
OCTO Technology
Développeur & Consultant Android / Java
..........................................................
50, Avenue des Champs-Elysées
75008 Paris
+33 (0)6.26.32.34.09
www.octo.com - blog.octo.com
www.usievents.com
...........................................................

@stephanenicolas
Copy link
Owner

Hi john,

I have updated the repo. Robolectric tests are now separate, in their own project. It's been hard to make cobertura coverage in that config, but it works now. Jacoco coverage still works like a charm for both unit and integration tests.

@stephanenicolas
Copy link
Owner

FYI, I could add the Robolectric tests back inside the project under tests and get working configuration within eclipse and maven. This new layout is much more standard for maven.

@johnfrey99
Copy link
Author

yeah I'm fine with that. The last of the eclipse developers on my team has left and the rest converted to Android Studio anyway. Again I appreciate all your hard work on this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants