@Test public void testJarOrder() throws Exception { Collection<LensSessionImpl.ResourceEntry> actualOrder = dbResService.getResourcesForDatabase(DB1); List<String> actualOrderList = new ArrayList<String>(); for (LensSessionImpl.ResourceEntry res : actualOrder) { actualOrderList.add(res.getUri()); } String[] expectedOrderArr = { "z_" + DB1 + ".jar", "y_" + DB1 + ".jar", "x_" + DB1 + ".jar", }; for (int i = 0; i < expectedOrderArr.length; i++) { Assert.assertTrue(actualOrderList.get(i).contains(expectedOrderArr[i]), actualOrderList.get(i) + " > " + expectedOrderArr[i]); } }
public Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database) { return dbResEntryMap.get(database); }
DatabaseResourceService extends AbstractService { public Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database) { return dbResEntryMap.get(database); } }
DatabaseResourceService extends AbstractService { public Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database) { return dbResEntryMap.get(database); } DatabaseResourceService(String name); }
DatabaseResourceService extends AbstractService { public Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database) { return dbResEntryMap.get(database); } DatabaseResourceService(String name); @Override synchronized void start(); @Override synchronized void stop(); Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database); }
DatabaseResourceService extends AbstractService { public Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database) { return dbResEntryMap.get(database); } DatabaseResourceService(String name); @Override synchronized void start(); @Override synchronized void stop(); Collection<LensSessionImpl.ResourceEntry> getResourcesForDatabase(String database); static final String NAME; static final String LOAD_RESOURCES_ERRORS; }