Assert.assertArrayEquals(targets.toArray(), codes.toArray());
}
@SuppressWarnings("unchecked")
public void testFindByExampleSorting() {
SystemCodes example = new SystemCodes();
example.setDisableProtection(true);
example.setOrderOption("key");
example.setOrderFlow("desc");
example.setCategory("COUNTRY");
List<SystemCodes> codes = dao.findByExample(example);
List<SystemCodes> targets = jdbcTemplate.query(
"select * from SYSTEM_CODES where CATEGORY_='COUNTRY' order by KEY_ desc",
new SystemCodesMapper());
Assert.assertArrayEquals(targets.toArray(), codes.toArray());