@Test public void createPacTag() throws Exception { PowerMockito.mockStatic(CommonUtils.class); PowerMockito.when(CommonUtils.getPropValue(anyString())).thenCallRealMethod(); final AutoFixManager classUnderTest = PowerMockito.spy(new AutoFixManager()); Whitebox.invokeMethod(classUnderTest, "createPacTag", "exceptionDetails123"); }
private Map<String, String> createPacTag(String exceptionDetails) throws Exception { String pacTagName = CommonUtils.getPropValue(PacmanSdkConstants.PACMAN_AUTO_FIX_TAG_NAME); String pacTagValue = CommonUtils.encryptB64(exceptionDetails); Map<String, String> tagMap = new HashMap<>(); tagMap.put(pacTagName, pacTagValue); return tagMap; }
AutoFixManager { private Map<String, String> createPacTag(String exceptionDetails) throws Exception { String pacTagName = CommonUtils.getPropValue(PacmanSdkConstants.PACMAN_AUTO_FIX_TAG_NAME); String pacTagValue = CommonUtils.encryptB64(exceptionDetails); Map<String, String> tagMap = new HashMap<>(); tagMap.put(pacTagName, pacTagValue); return tagMap; } }
AutoFixManager { private Map<String, String> createPacTag(String exceptionDetails) throws Exception { String pacTagName = CommonUtils.getPropValue(PacmanSdkConstants.PACMAN_AUTO_FIX_TAG_NAME); String pacTagValue = CommonUtils.encryptB64(exceptionDetails); Map<String, String> tagMap = new HashMap<>(); tagMap.put(pacTagName, pacTagValue); return tagMap; } AutoFixManager(); }
AutoFixManager { private Map<String, String> createPacTag(String exceptionDetails) throws Exception { String pacTagName = CommonUtils.getPropValue(PacmanSdkConstants.PACMAN_AUTO_FIX_TAG_NAME); String pacTagValue = CommonUtils.encryptB64(exceptionDetails); Map<String, String> tagMap = new HashMap<>(); tagMap.put(pacTagName, pacTagValue); return tagMap; } AutoFixManager(); Map<String, Object> performAutoFixs(Map<String, String> ruleParam,
            Map<String, List<IssueException>> exemptedResourcesForRule,
            Map<String, IssueException> individuallyExcemptedIssues); static void main(String[] args); }
AutoFixManager { private Map<String, String> createPacTag(String exceptionDetails) throws Exception { String pacTagName = CommonUtils.getPropValue(PacmanSdkConstants.PACMAN_AUTO_FIX_TAG_NAME); String pacTagValue = CommonUtils.encryptB64(exceptionDetails); Map<String, String> tagMap = new HashMap<>(); tagMap.put(pacTagName, pacTagValue); return tagMap; } AutoFixManager(); Map<String, Object> performAutoFixs(Map<String, String> ruleParam,
            Map<String, List<IssueException>> exemptedResourcesForRule,
            Map<String, IssueException> individuallyExcemptedIssues); static void main(String[] args);  }