Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Easily removing JUnit support from exported runnable JAR?
Easily removing JUnit support from exported runnable JAR? [message #1394593] Sat, 05 July 2014 15:10
Gary Worsham is currently offline Gary WorshamFriend
Messages: 176
Registered: September 2013
Senior Member
I have put some JUnit code into my project along with JUnit and hamcrest libraries.

When I export everything to a runnable JAR, all of this stuff goes with it. I don't really want to include test code in my releases. If nothing else, it makes the JAR file about 4 times as big.

A few times I have gone into the JAR file using an archive editor and manually pulled out libraries and classes associated with JUnit. This is tedious and probably error-prone.

Is there a better way to exclude the JUnit stuff when exporting a runnable JAR?

Thanks,

GW

update - I did find a similar discussion at StackOverflow:

http://stackoverflow.com/questions/11641546/exclude-junit-from-eclipse-exported-jar

Seems like it's possible... I'm looking for "easy"! Laughing

[Updated on: Mon, 07 July 2014 13:41]

Report message to a moderator

Previous Topic:Eclipse Juno Don't Create main_activity.xml
Next Topic:Autocomplete mode for CSS not working on Eclipse Luna Javafx project
Goto Forum:
  


Current Time: Mon Nov 23 17:10:53 GMT 2020

Powered by FUDForum. Page generated in 0.01552 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top