ServerDao extends BaseDao { public Server getServerById(Long id) throws SQLException { Server server = new Server(); server.setId(id); return this.getDasClient().queryByPk(server); }  Server getServerById(Long id); Long insertServer(Server server); int updateServer(Server server); int deleteServer(Server server); int deleteServerAndServerConfigByServerId(Long serverId); boolean isNotExistByIpAndPort(Server server); int deleteServerByServerGroupId(Long serverGroupId); int changeServerGroup(long serverId, long serverGroupId); List<Server> getServersByServerGroupId(Long serverGroupId); Long getServerTotalCount(Paging<Server> paging); List<ServerView> findServerPageList(Paging<Server> paging);  }
@Test public void getServerById() throws Exception { Long id = 5L; Server server = serverDao.getServerById(id); System.out.println("getServerById :-------> " + server.toString()); Assert.assertTrue(server.getId() == id); }