diff options
author | Lars Grefer <eclipse@larsgrefer.de> | 2020-08-13 03:32:01 +0200 |
---|---|---|
committer | Lars Grefer <eclipse@larsgrefer.de> | 2020-08-13 03:32:01 +0200 |
commit | 85ccda9262dee2446eb53ceb5fc07b1d36ff6630 (patch) | |
tree | 0cc6526e3af28ddd46be091a76f75fbcaf495fc0 /weaver | |
parent | 0377c66272ec5375bc5be59460880fafcb60b4f3 (diff) | |
download | aspectj-85ccda9262dee2446eb53ceb5fc07b1d36ff6630.tar.gz aspectj-85ccda9262dee2446eb53ceb5fc07b1d36ff6630.zip |
Fix Testcase
Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
Diffstat (limited to 'weaver')
-rw-r--r-- | weaver/src/test/java/org/aspectj/weaver/bcel/ClasspathManagerTestCase.java | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/weaver/src/test/java/org/aspectj/weaver/bcel/ClasspathManagerTestCase.java b/weaver/src/test/java/org/aspectj/weaver/bcel/ClasspathManagerTestCase.java index f4f84f168..0cf4cc8ca 100644 --- a/weaver/src/test/java/org/aspectj/weaver/bcel/ClasspathManagerTestCase.java +++ b/weaver/src/test/java/org/aspectj/weaver/bcel/ClasspathManagerTestCase.java @@ -44,12 +44,14 @@ public class ClasspathManagerTestCase extends TestCase { private static String findJvm(String pattern, String jar) { String start = System.getProperty("user.home")+"/jvms"; - for (File f: new File(start).listFiles()) { - if (f.isDirectory() && Pattern.matches(pattern, f.getName())) { - File result = walk(f, jar); - if (result !=null) { - System.out.println("For "+pattern+" found "+result.getAbsolutePath()); - return result.getAbsolutePath(); + if (new File(start).isDirectory()) { + for (File f : new File(start).listFiles()) { + if (f.isDirectory() && Pattern.matches(pattern, f.getName())) { + File result = walk(f, jar); + if (result != null) { + System.out.println("For " + pattern + " found " + result.getAbsolutePath()); + return result.getAbsolutePath(); + } } } } |