dgraham 2003/09/28 12:26:17
Modified: validator/src/test/org/apache/commons/validator
TestCommon.java
Log:
Cleaned up exception handling.
Revision Changes Path
1.3 +10 -5
jakarta-commons/validator/src/test/org/apache/commons/validator/TestCommon.java
Index: TestCommon.java
===================================================================
RCS file:
/home/cvs/jakarta-commons/validator/src/test/org/apache/commons/validator/TestCommon.java,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- TestCommon.java 6 Sep 2003 05:22:47 -0000 1.2
+++ TestCommon.java 28 Sep 2003 19:26:17 -0000 1.3
@@ -70,13 +70,15 @@
import org.apache.commons.logging.LogFactory;
/**
- * Consolidates reading in xml config file into parent class.
+ * Consolidates reading in XML config file into parent class.
*/
abstract public class TestCommon extends TestCase {
+
/**
* Resources used for validation tests.
*/
protected ValidatorResources resources = null;
+
/**
* Commons Logging instance.
*/
@@ -97,14 +99,17 @@
try {
in = this.getClass().getResourceAsStream(file);
resources = new ValidatorResources(in);
+
} catch (IOException e) {
log.error(e.getMessage(), e);
throw e;
+
} finally {
if (in != null) {
try {
in.close();
- } catch (Exception e) {
+ } catch (IOException e) {
+ log.error(e.getMessage(), e);
}
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]