You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@oodt.apache.org by ma...@apache.org on 2017/08/30 16:39:56 UTC

[27/52] [abbrv] oodt git commit: Merge and apply robust changes for stack trace print in tests.

Merge and apply robust changes for stack trace print in tests.


Project: http://git-wip-us.apache.org/repos/asf/oodt/repo
Commit: http://git-wip-us.apache.org/repos/asf/oodt/commit/b66a68dc
Tree: http://git-wip-us.apache.org/repos/asf/oodt/tree/b66a68dc
Diff: http://git-wip-us.apache.org/repos/asf/oodt/diff/b66a68dc

Branch: refs/heads/master
Commit: b66a68dc9fda88156d3dfb06b3f063357c957510
Parents: 59d7f3c
Author: Chris Mattmann <ma...@apache.org>
Authored: Fri Jul 14 09:24:50 2017 -0700
Committer: Chris Mattmann <ma...@apache.org>
Committed: Fri Jul 14 09:24:50 2017 -0700

----------------------------------------------------------------------
 .../distributed/DistributedConfigurationManagerTest.java       | 6 ++++++
 1 file changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/oodt/blob/b66a68dc/config/src/test/java/org/apache/oodt/config/distributed/DistributedConfigurationManagerTest.java
----------------------------------------------------------------------
diff --git a/config/src/test/java/org/apache/oodt/config/distributed/DistributedConfigurationManagerTest.java b/config/src/test/java/org/apache/oodt/config/distributed/DistributedConfigurationManagerTest.java
index fde20f8..e531caf 100644
--- a/config/src/test/java/org/apache/oodt/config/distributed/DistributedConfigurationManagerTest.java
+++ b/config/src/test/java/org/apache/oodt/config/distributed/DistributedConfigurationManagerTest.java
@@ -25,6 +25,7 @@ import org.junit.AfterClass;
 import org.junit.Assert;
 import org.junit.BeforeClass;
 import org.junit.Test;
+import static org.junit.Assert.fail;
 import org.springframework.context.ApplicationContext;
 import org.springframework.context.support.ClassPathXmlApplicationContext;
 
@@ -83,6 +84,10 @@ public class DistributedConfigurationManagerTest extends AbstractDistributedConf
                 try (InputStream in = new FileInputStream(originalFile)) {
                     properties.load(in);
                 }
+		catch (Exception e){
+		    e.printStackTrace();
+		    fail(e.getMessage());
+		}
 
                 for (String key : properties.stringPropertyNames()) {
                     Assert.assertEquals(properties.getProperty(key), System.getProperty(key));
@@ -91,6 +96,7 @@ public class DistributedConfigurationManagerTest extends AbstractDistributedConf
                 String fileName = FilePathUtils.fixForComponentHome(publisher.getComponent(), entry.getValue());
                 fileName = fileName.startsWith(SEPARATOR) ? fileName.substring(1) : fileName;
                 File downloadedFile = new File(fileName);
+		Assert.notNull(downloadedFile);
                 Assert.assertTrue(downloadedFile.exists());
             }