ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 34748] New: - [PATCH] JUnit Task enhancement to allow a single test method to be specified
Date Wed, 04 May 2005 21:29:47 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=34748>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=34748

           Summary: [PATCH] JUnit Task enhancement to allow a single test
                    method to be specified
           Product: Ant
           Version: 1.6.3
          Platform: Other
        OS/Version: other
            Status: NEW
          Severity: enhancement
          Priority: P2
         Component: Optional Tasks
        AssignedTo: dev@ant.apache.org
        ReportedBy: sissonj@insession.com


Currently, when a JUnit test is executed via the Ant JUnit task ( 
http://ant.apache.org/manual/OptionalTasks/junit.html ), a number of test
methods in the test class are executed and there is no support in the JUnit task
for instructing JUnit to execute a single test method (like the way JUnit
provides this functionality via the -m parameter in the junit.textui.TestRunner
class).

This patch (generated against the ANT_16_BRANCH in CVS) provides the ability to
specify a test method name to be executed in the new "method" attribute of the
nested "test" element in the <junit> ant task.

Reasons why enhancing the Ant JUnit task to allow the execution a single test
method is desirable:

* When a test method fails, you can run the failing test method under the Java
debugger without having to wait for the other test methods to complete
(especially where some of the other tests are long running).
* Ability to quickly test code changes that fix a failing test
* Ability to run under a Java profiler, a single test method that appears to be
running slower than expected (without the overhead of running the profiler
whilst other test methods are being executed).
* Speeds up the test/debug cycle when you are running on a busy system or slow
hardware
* No need to make code changes to force one test to be run when you want to
debug a single test.

The patch also adds 2 tests for the new functionality, which have been executed
along with the existing Ant JUnit tests in the ANT_16_BRANCH.

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message