@Test
  public void testInsertMonth() throws Exception {
    long writeSuccessCountBefore = metrics.writeSuccessCount.getCount();
    aggregatedAccountReportsDao.updateMonth(clusterName, "2020-01");
    verify(mockConnection).prepareStatement(anyString());
    assertEquals("Write success count should be " + (writeSuccessCountBefore + 1), writeSuccessCountBefore + 1,
        metrics.writeSuccessCount.getCount());

    aggregatedAccountReportsDao.updateMonth(clusterName, "2020-01");
    assertEquals("Write success count should be " + (writeSuccessCountBefore + 2), writeSuccessCountBefore + 2,
        metrics.writeSuccessCount.getCount());
  }
Utility to get a {@link DataSource}.
@param mockConnection the connection to use.
@return the {@link DataSource}.
@throws SQLException
ambry-mysql/src/test/java/com/github/ambry/accountstats/AggregatedAccountReportsDaoTest.java