You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by se...@apache.org on 2011/12/09 18:05:16 UTC
svn commit: r1212522 -
/commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java
Author: sebb
Date: Fri Dec 9 17:05:15 2011
New Revision: 1212522
URL: http://svn.apache.org/viewvc?rev=1212522&view=rev
Log:
Simplify; avoid potential NPE warnings
Modified:
commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java
Modified: commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java
URL: http://svn.apache.org/viewvc/commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java?rev=1212522&r1=1212521&r2=1212522&view=diff
==============================================================================
--- commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java (original)
+++ commons/proper/digester/trunk/src/test/java/org/apache/commons/digester3/CallMethodRuleTestCase.java Fri Dec 9 17:05:15 2011
@@ -268,19 +268,10 @@ public class CallMethodRuleTestCase
}).newDigester();
- // Parse our test input
- NamedBean root1 = null;
- try
- {
- // an exception will be thrown if the method can't be found
- root1 = digester.parse( getInputStream( "Test8.xml" ) );
+ // Parse our test input
+ // an exception will be thrown if the method can't be found
+ NamedBean root1 = digester.parse( getInputStream( "Test8.xml" ) );
- }
- catch ( Throwable t )
- {
- // this means that the method can't be found and so the test fails
- fail( "Digester threw Exception: " + t );
- }
// if the CallMethodRule were to incorrectly invoke the method call
// on the second-created NamedBean instance, then the root one would