This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 56634 - Allow running main class in test sources
Summary: Allow running main class in test sources
Status: RESOLVED DUPLICATE of bug 119922
Alias: None
Product: java
Classification: Unclassified
Component: Project (show other bugs)
Version: 4.x
Hardware: All All
: P3 blocker with 2 votes (vote)
Assignee: Jan Jancura
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-18 10:23 UTC by Petr Jiricka
Modified: 2009-07-08 10:57 UTC (History)
1 user (show)

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Petr Jiricka 2005-03-18 10:23:17 UTC
Currently, when running a file (Shit+F6) in the Test Sources, the project
attempts to run the currently selected class using JUnit. However, for classes
with main() method which are not JUnit tests, it would be useful to run the
main() method instead.
 
Filing on behalf of Mark.deReeper at sun.com.
Comment 1 cemerick 2008-08-19 11:52:52 UTC
This has sat dormant for a long time.  Doing this in eclipse (for example) is trivial.  Simply providing the option of
adding the test classpath entries to a run configuration would do the trick...
Comment 2 ulim 2009-02-13 10:02:48 UTC
Another example for the need of a main class under test: stress tests.
Comment 3 ulim 2009-07-08 10:57:59 UTC

*** This issue has been marked as a duplicate of 119922 ***