jMock

Lost test Exception in org.jmock.core.VerifyingTestCase.runBare()

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 1.2.0
  • Fix Version/s: None
  • Component/s: JMock 1.x.x Library
  • Labels:
    None
  • Environment:
    Java 1.4
    JUnit 3.8.2
  • Number of attachments :
    0

Description

In org.jmock.core.VerifyingTestCase

/* This is virtually a copy/paste of the same invokedMethod in the TestCase class to allow

  • overriding of runTest in the normal manner.
    *
  • @see junit.framework.TestCase#runBare()
    */
    public void runBare() throws Throwable
    Unknown macro: { setUp(); try { runTest(); verify(); } finally { tearDown(); } }

Exception appen in text was lost on try (no catch no throw). In super method junit.framework.TestCase.runBare() there is :
/**

  • Runs the bare test sequence.
  • @exception Throwable if any exception is thrown
    */
    public void runBare() throws Throwable {
    Throwable exception= null;
    setUp();
    try { runTest(); } catch (Throwable running) { exception= running; }
    finally
    Unknown macro: { try { tearDown(); } catch (Throwable tearingDown) { if (exception == null) exception= tearingDown; } }

    if (exception != null) throw exception;
    }
    And here it's take care of test Exception.

Activity

There are no comments yet on this issue.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated: