[jira] Created: (JMOCK-206) Lost test Exception in org.jmock.core.VerifyingTestCase.runBare()

View: New views
2 Messages — Rating Filter:   Alert me  

[jira] Created: (JMOCK-206) Lost test Exception in org.jmock.core.VerifyingTestCase.runBare()

by JIRA jira@codehaus.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

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

                 Key: JMOCK-206
                 URL: http://jira.codehaus.org/browse/JMOCK-206
             Project: jMock
          Issue Type: Bug
          Components: Library
    Affects Versions: 1.2.0
         Environment: Java 1.4
JUnit 3.8.2
            Reporter: Frédéric Rodrigo


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 {
        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 {
                        try {
                                tearDown();
                        } catch (Throwable tearingDown) {
                                if (exception == null) exception= tearingDown;
                        }
                }
                if (exception != null) throw exception;
        }
And here it's take care of test Exception.


--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



[jira] Updated: (JMOCK-206) Lost test Exception in org.jmock.core.VerifyingTestCase.runBare()

by JIRA jira@codehaus.org :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


     [ http://jira.codehaus.org/browse/JMOCK-206?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Nat Pryce updated JMOCK-206:
----------------------------

    Component/s:     (was: JMock 2.x.x Library)
                 JMock 1.x.x Library

> Lost test Exception in org.jmock.core.VerifyingTestCase.runBare()
> -----------------------------------------------------------------
>
>                 Key: JMOCK-206
>                 URL: http://jira.codehaus.org/browse/JMOCK-206
>             Project: jMock
>          Issue Type: Bug
>          Components: JMock 1.x.x Library
>    Affects Versions: 1.2.0
>         Environment: Java 1.4
> JUnit 3.8.2
>            Reporter: Frédéric Rodrigo
>
> 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 {
>         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 {
> try {
> tearDown();
> } catch (Throwable tearingDown) {
> if (exception == null) exception= tearingDown;
> }
> }
> if (exception != null) throw exception;
> }
> And here it's take care of test Exception.

--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email