AAI-1523 Batch reformat aai-core
[aai/aai-common.git] / aai-core / src / test / java / org / onap / aai / util / JettyObfuscationConversionCommandLineUtilTest.java
index 071b630..b060a67 100644 (file)
@@ -19,6 +19,7 @@
  * limitations under the License.
  * ============LICENSE_END=========================================================
  */
+
 package org.onap.aai.util;
 
 import static org.junit.Assert.assertTrue;
@@ -39,12 +40,12 @@ public class JettyObfuscationConversionCommandLineUtilTest {
      */
     @Test
     public void test() {
-        //setup, this will catch main's print statements for evaluation
+        // setup, this will catch main's print statements for evaluation
         PrintStream oldOutputStream = System.out;
         System.setOut(new PrintStream(testOut));
 
-        /* ------ TEST OBFUSCATION ----*/
-        JettyObfuscationConversionCommandLineUtil.main(new String[]{"-e", "hello world"});
+        /* ------ TEST OBFUSCATION ---- */
+        JettyObfuscationConversionCommandLineUtil.main(new String[] {"-e", "hello world"});
         /*
          * testOut was also catching any logging statements which interfered with result checking.
          * This regex business was the workaround - it tries to find the expected value in
@@ -56,21 +57,20 @@ public class JettyObfuscationConversionCommandLineUtilTest {
         Matcher obfMatch = obfExpectPat.matcher(obfResult);
         assertTrue(obfMatch.find());
 
-        testOut.reset(); //clear out previous result
+        testOut.reset(); // clear out previous result
 
         /* ------ TEST DEOBFUSCATION ----- */
-        JettyObfuscationConversionCommandLineUtil.main(new String[]{"-d", obfExpected});
+        JettyObfuscationConversionCommandLineUtil.main(new String[] {"-d", obfExpected});
         String deobfResult = testOut.toString();
         String deobfExpected = "hello world";
         Pattern deobfExpectPat = Pattern.compile(deobfExpected);
         Matcher deobfMatch = deobfExpectPat.matcher(deobfResult);
         assertTrue(deobfMatch.find());
 
-        //clean up, resets to stdout
+        // clean up, resets to stdout
         System.setOut(oldOutputStream);
     }
 
-    
     /**
      * Test.
      */
@@ -78,8 +78,8 @@ public class JettyObfuscationConversionCommandLineUtilTest {
     public void testUsage() {
         System.setOut(new PrintStream(testOut));
 
-        /* ------ TEST OBFUSCATION ----*/
-        JettyObfuscationConversionCommandLineUtil.main(new String[]{"-f", "hello world"});
+        /* ------ TEST OBFUSCATION ---- */
+        JettyObfuscationConversionCommandLineUtil.main(new String[] {"-f", "hello world"});
         /*
          * testOut was also catching any logging statements which interfered with result checking.
          * This regex business was the workaround - it tries to find the expected value in
@@ -87,9 +87,8 @@ public class JettyObfuscationConversionCommandLineUtilTest {
          */
         String obfResult = testOut.toString();
         assertTrue(obfResult.startsWith("failed to parse input"));
-        
-        testOut.reset(); //clear out previous result
 
+        testOut.reset(); // clear out previous result
 
     }