title: How to write junit for this code?
body: <p>How do I call populateMapWithFormattedDates method in JUnit and how to write JUnit populateMapWithFormattedDates for this method. I dont know how to write JUnit for nested methods so kindly help. </p>
  
  <pre><code>protected Map&lt;String, String&gt; populateDispatch(final RequestDispatchData requestDispatchData)
      {
          final Map&lt;String, String&gt; map = getDispatchFieldMapper().populateMapper(requestDispatchData);
          populateMapWithFormattedDates(requestDispatchData, map);
   }
  
  
  private void populateMapWithFormattedDates(final RequestDispatchData requestDispatchData, final Map&lt;String, String&gt; map)
      {
          String dateFormatted = map.get("ticket_date");
          Date date = null;
          try
          {
              date = new SimpleDateFormat("MM/dd/yy").parse(dateFormatted);
          }
          catch (ParseException parseException)
          {
              customLogger.logMessage(diagnosticMethodSignature, DiagnosticType.EXCEPTION,
                      "Exception in parsing start date of ticket " + parseException);
          }
          map.put("startDateDDMMYY", DateEnum.DDMMYY.getFormattor().format(date));
          map.put("startDateDDMMMYY", DateEnum.DDMMMYY.getFormattor().format(date));
          map.put("startDateDMY", DateEnum.DMY.getFormattor().format(date));
          map.put("startDateYYMMDD", DateEnum.YYMMDD.getFormattor().format(date));
      }
  </code></pre>