예제 #1
0
  public void testFindFilesSubDir() throws Exception {
    Finder f = FinderFactory.getFinder("com.redhat.rhn.common.finder");
    assertNotNull(f);

    List<String> result = f.find(".class");
    assertEquals(6, result.size());
  }
예제 #2
0
 public void testFindExcluding() throws Exception {
   Finder f = FinderFactory.getFinder("com.redhat.rhn.common.finder");
   assertNotNull(f);
   String[] sarr = {"Test"};
   List<String> result = f.findExcluding(sarr, "class");
   assertEquals(4, result.size());
 }
예제 #3
0
  public void testFindFiles() throws Exception {
    Finder f = FinderFactory.getFinder("com.redhat.rhn.common.finder.test");
    assertNotNull(f);

    List<String> result = f.find("Test.class");
    String first = result.get(0);
    assertTrue(first.startsWith("com/redhat/rhn/common/finder/test"));
    assertEquals(2, result.size());
  }