@Test
public void testDeleteUserData() {

    Identity identityMock = mock(Identity.class);
    String newDeletedUserName = "deletedUserName";
    List qtiResultSets = new ArrayList();
    QTIResultSet qtiResultSet1 = mock(QTIResultSet.class);
    qtiResultSets.add(qtiResultSet1);
    QTIResultSet qtiResultSet2 = mock(QTIResultSet.class);
    qtiResultSets.add(qtiResultSet2);
    when(qtiResultDaoMock.findQtiResultSets(identityMock)).thenReturn(qtiResultSets);
    qtiResultServiceImpl.deleteUserData(identityMock, newDeletedUserName);
    verify(qtiResultDaoMock).deleteResultSet(qtiResultSet1);
    verify(qtiResultDaoMock).deleteResultSet(qtiResultSet2);
}