Repository: incubator-gobblin
Updated Branches:
  refs/heads/master e19f21093 -> ec2fe0487


[GOBBLIN-336] Add a test testGetJavaClassPath

Closes #2214 from HappyRay/add-unit-test-for-get-
classpath-wrapper


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

Branch: refs/heads/master
Commit: ec2fe04876f1fa2eeb844879329fd31f710895a4
Parents: e19f210
Author: Ray Yang <[email protected]>
Authored: Mon Dec 18 14:51:04 2017 -0800
Committer: Abhishek Tiwari <[email protected]>
Committed: Mon Dec 18 14:51:04 2017 -0800

----------------------------------------------------------------------
 .../gobblin/util/SystemPropertiesWrapperTest.java  | 17 ++++++++++++++---
 1 file changed, 14 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-gobblin/blob/ec2fe048/gobblin-utility/src/test/java/org/apache/gobblin/util/SystemPropertiesWrapperTest.java
----------------------------------------------------------------------
diff --git 
a/gobblin-utility/src/test/java/org/apache/gobblin/util/SystemPropertiesWrapperTest.java
 
b/gobblin-utility/src/test/java/org/apache/gobblin/util/SystemPropertiesWrapperTest.java
index 178520e..5b5ff63 100644
--- 
a/gobblin-utility/src/test/java/org/apache/gobblin/util/SystemPropertiesWrapperTest.java
+++ 
b/gobblin-utility/src/test/java/org/apache/gobblin/util/SystemPropertiesWrapperTest.java
@@ -24,14 +24,25 @@ import static org.assertj.core.api.Assertions.assertThat;
 
 public class SystemPropertiesWrapperTest {
 
+  final SystemPropertiesWrapper propertiesWrapper = new 
SystemPropertiesWrapper();
+
   @Test
   public void testGetJavaHome() {
-    final SystemPropertiesWrapper propertiesWrapper = new 
SystemPropertiesWrapper();
-    final String home = propertiesWrapper.getJavaHome();
-    // It's hard to assert where the java JRE home directory is used to launch 
this process.
+    final String home = this.propertiesWrapper.getJavaHome();
+    // It's hard to assert which java JRE home directory is used to launch 
this process.
     // This test is designed to print out the actual value for debugging and 
demonstration
     // purposes.
     System.out.println(home);
     assertThat(home).isNotEmpty();
   }
+
+  @Test
+  public void testGetJavaClassPath() {
+    final String classPath = this.propertiesWrapper.getJavaClassPath();
+    // It's hard to assert what classpath is used to launch this process.
+    // This test is designed to print out the actual value for debugging and 
demonstration
+    // purposes.
+    System.out.println(classPath);
+    assertThat(classPath).isNotEmpty();
+  }
 }

Reply via email to