diff options
author | 2017-05-15 12:53:18 -0400 | |
---|---|---|
committer | 2017-05-15 13:55:23 -0400 | |
commit | 7e547eaa55920dfbc9691eab33bb728395b50cf2 (patch) | |
tree | 5d0d64928b4754f65b427cb79b43718f16019582 /PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java | |
parent | dda032f8bb161d54eb1f59de2b4a3efb774fc4d1 (diff) |
Policy TestSuite Enabled
Change-Id: I9f98c7dcdcf98713d73544956d873a84fc82adf7
Signed-off-by: Ravindra Bakkamanthala <rb7147@att.com>
Diffstat (limited to 'PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java')
-rw-r--r-- | PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java b/PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java index c78fc6f11..6ca340efe 100644 --- a/PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java +++ b/PolicyEngineClient/src/main/java/org/openecomp/policyEngine/GeneralTestClient.java @@ -47,6 +47,8 @@ import org.json.simple.JSONObject; import org.json.simple.parser.JSONParser; import org.openecomp.policy.api.PolicyEngine; import org.openecomp.policy.api.PolicyEngineException; +import org.openecomp.policy.common.logging.flexlogger.FlexLogger; +import org.openecomp.policy.common.logging.flexlogger.Logger; /** * Class reads from .testCases file and run the test cases available in the file @@ -58,6 +60,9 @@ import org.openecomp.policy.api.PolicyEngineException; * */ public class GeneralTestClient { + + private static final Logger LOGGER = FlexLogger.getLogger(GeneralTestClient.class); + static int totalTC = 0, passTC = 0, failTC = 0; public static void main(String[] args) { @@ -275,29 +280,26 @@ public class GeneralTestClient { } } catch (PolicyEngineException e) { - // TODO Auto-generated catch block printResult(id, testFor, testCaseDescription, "FAILED"); failTCforFile++; failTC++; - e.printStackTrace(); + LOGGER.error("Exception Occured"+e); } catch (Exception e) { - // TODO Auto-generated catch block printResult(id, testFor, testCaseDescription, "FAILED"); failTCforFile++; failTC++; - e.printStackTrace(); + LOGGER.error("Exception Occured"+e); } } } catch (FileNotFoundException ex) { - ex.printStackTrace(); + LOGGER.error("Exception Occured due to File not found"+ex); } catch (IOException ex) { - ex.printStackTrace(); + LOGGER.error("Exception Occured"+ex); } catch (NullPointerException ex) { - ex.printStackTrace(); + LOGGER.error("Exception Occured due to Null Pointer"+ex); } catch (org.json.simple.parser.ParseException e) { - // TODO Auto-generated catch block - e.printStackTrace(); + LOGGER.error("Exception Occured while Parsing"+e); } } System.out.println("\n\n\t Summary for the file: TOTAL: " |