AnalyticsAppsDAO { public List<String> listApps(String industry, String category) { Session session = sessionFactory.openSession(); session.beginTransaction(); Criteria criteria = session.createCriteria(com.wipro.ats.bdre.md.dao.jpa.AnalyticsApps.class).add(Restrictions.eq("industryName", industry)).add(Restrictions.eq("categoryName", category)); criteria.setProjection(Projections.distinct(Projections.property("appName"))); LOGGER.info("number of apps" + criteria.list().size()); List<String> apps = criteria.list(); session.getTransaction().commit(); session.close(); return apps; }  Long insert(com.wipro.ats.bdre.md.dao.jpa.AnalyticsApps analyticApps); List<String> listIndustries(); List<String> listCategories(String industry); List<String> listApps(String industry, String category); List<String> getDashBoardURL(String industry, String category, String app); List<String> getJson(String industry, String category, String app);  }
@Ignore @Test public void testListApp() throws Exception{ LOGGER.info(analyticsAppsDAO.listApps("Banking","cat1")); }