|
From: SourceForge.net <no...@so...> - 2009-10-29 14:17:31
|
Feature Requests item #2888680, was opened at 2009-10-29 09:59 Message generated for change (Settings changed) made by davidnorthox You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=365278&aid=2888680&group_id=15278 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: None Group: None >Status: Open Resolution: None Priority: 5 Private: No Submitted By: David North (davidnorthox) Assigned to: Nobody/Anonymous (nobody) Summary: Support failing with an exception Initial Comment: When writing custom assert methods for use in junit tests, it's hard to propagate an exception that caused the assertion to fail. This could be fixed by: - adding an Assert.fail method which takes an exception as well as a message - adding a constructor to AssertionFailedError which takes another exception ---------------------------------------------------------------------- >Comment By: David North (davidnorthox) Date: 2009-10-29 14:17 Message: Not particularly, it's just a bit nicer when running the tests in eclipse to see passes or failures rather than exceptions (which are flagged red rather than blue when running from eclipse, even under junit 4). ---------------------------------------------------------------------- Comment By: David Saff (dsaff) Date: 2009-10-29 12:17 Message: In JUnit 4, we've removed the distinction between errors and failures. In this scheme, you would simply rethrow the exception, or let it propagate. Do you find this causes problems? ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=365278&aid=2888680&group_id=15278 |