Author: nbubna
Date: Wed Sep  3 21:21:20 2008
New Revision: 691869

URL: http://svn.apache.org/viewvc?rev=691869&view=rev
Log:
don't let gump get out of giving some info

Modified:
    
velocity/engine/trunk/src/test/org/apache/velocity/test/ResourceExistsTestCase.java

Modified: 
velocity/engine/trunk/src/test/org/apache/velocity/test/ResourceExistsTestCase.java
URL: 
http://svn.apache.org/viewvc/velocity/engine/trunk/src/test/org/apache/velocity/test/ResourceExistsTestCase.java?rev=691869&r1=691868&r2=691869&view=diff
==============================================================================
--- 
velocity/engine/trunk/src/test/org/apache/velocity/test/ResourceExistsTestCase.java
 (original)
+++ 
velocity/engine/trunk/src/test/org/apache/velocity/test/ResourceExistsTestCase.java
 Wed Sep  3 21:21:20 2008
@@ -42,6 +42,7 @@
 
     public void setUp() throws Exception
     {
+try {
         velocity = new VelocityEngine();
         velocity.setProperty("resource.loader", "file,string");
         velocity.setProperty("file.resource.loader.path", path);
@@ -51,10 +52,16 @@
         logger.on();
         velocity.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM, logger);
         velocity.setProperty("runtime.log.logsystem.test.level", "debug");
+} catch (Exception e) {
+    System.out.println("exception via gump: "+e);
+    e.printStackTrace();
+    System.out.println("log: "+logger.getLog());
+}
     }
 
     public void testFileResourceExists() throws Exception
     {
+try {
         if (!velocity.resourceExists("testfile.vm"))
         {
             String msg = "testfile.vm was not found in path "+path;
@@ -75,12 +82,23 @@
             System.out.println(msg);
             fail(msg);
         }
+} catch (Exception e) {
+    System.out.println("exception via gump: "+e);
+    e.printStackTrace();
+    System.out.println("log: "+logger.getLog());
+}
     }
 
     public void testStringResourceExists() throws Exception
     {
+try {
         assertFalse(velocity.resourceExists("foo.vm"));
         StringResourceLoader.getRepository().putStringResource("foo.vm", "Make 
it so!");
         assertTrue(velocity.resourceExists("foo.vm"));
+} catch (Exception e) {
+    System.out.println("exception via gump: "+e);
+    e.printStackTrace();
+    System.out.println("log: "+logger.getLog());
+}
     }
 }


Reply via email to