Skip to content

Commit

Permalink
Tests: ignore not properly defined JCL_SRCROOT classpath variable
Browse files Browse the repository at this point in the history
This variable is defined as "src" and seem to be not always available

See eclipse-jdt#2536
  • Loading branch information
iloveeclipse authored and gayanper committed Sep 7, 2024
1 parent 55dfa51 commit d9135d1
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3741,14 +3741,20 @@ public void setUpJCLClasspathVariables(String compliance, boolean useFullJCL) th
if(!variable.contains("JCL")) {
continue;
}
IPath varPath = JavaCore.getClasspathVariable(variable);
if(varPath != null) {
System.out.println("Classpath variable '" + variable + "', path: '" + varPath + "', file size: " + varPath.toFile().length());
}
if(variable.startsWith("CONVERTER_JCL") && variable.endsWith("_SRCROOT")) {
// CONVERTER_JCL10_SRCROOT is not properly defined
continue;
}
IPath varPath = JavaCore.getClasspathVariable(variable);
if(variable.equals("JCL_SRCROOT")) {
// JCL_SRCROOT points to "src" !?! which may not exist
continue;
}
assertNotNull("Should have path defined: '" + variable + "'", varPath);
assertTrue("Should exist on disk: '" + variable + "' defined as " + varPath, varPath.toFile().exists());
System.out.println("Defined classpath variable '" + variable + "' with path " + varPath + " and file size " + varPath.toFile().length());
}
}
@Override
Expand Down

0 comments on commit d9135d1

Please sign in to comment.