Code example for AbstractTransactionalTestNGSpringContextTests

Methods: assertEquals

0
        String usernamePattern = "Us"; 
        int resultCount = 2; 
        createUser("User1", true); 
        createUser("uSer2", true); 
        createUser("user3", true); 
        assertEquals(dao.getUsernames(usernamePattern, resultCount).size(), 2); 
    } 
 
    @Test 
    public void getUsernamesEnabledUsers() { 
        String usernamePattern = "Us"; 
        int resultCount = 5; 
        createUser("User1", true); 
        createUser("uSer2", true); 
        createUser("user3", false); 
        assertEquals(dao.getUsernames(usernamePattern, resultCount).size(), 2); 
    } 
 
    @Test 
    public void getUsernamesWithSpecialCharacters() {