@Test(description = "This test case tests handling PolicyComplianceException when checking policy compliance",
      dependsOnMethods = "testAddProfileThrowingMonitoringDAOException")
public void testAddProfileThrowingMonitoringDAOException2() throws Exception {

    MonitoringDAO monitoringDAO = spy(MonitoringDAOImpl.class);
    doThrow(new MonitoringDAOException()).when(monitoringDAO).deleteNoneComplianceData(anyInt());
    DeviceIdentifier deviceIdentifier = new DeviceIdentifier();
    deviceIdentifier.setType(DEVICE_TYPE_E);
    deviceIdentifier.setId(String.valueOf(device5.getDeviceIdentifier()));
    testThrowingException(monitoringManager, deviceIdentifier, d -> monitoringManager.checkPolicyCompliance((DeviceIdentifier) d, new ArrayList<ComplianceFeature>()), "monitoringDAO",
                          monitoringDAO,
                          MonitoringDAOException.class);
}