aboutsummaryrefslogtreecommitdiffstats
path: root/ajdoc/testsrc/org/aspectj
diff options
context:
space:
mode:
authorAndy Clement <aclement@pivotal.io>2017-11-09 13:14:02 -0800
committerAndy Clement <aclement@pivotal.io>2017-11-09 13:14:02 -0800
commitd92319c43f5723d57887e09f2a839ee5b595fcfd (patch)
tree155e25d455e598ff5b55b0563645d4af23903bb4 /ajdoc/testsrc/org/aspectj
parent6765fdc34c775e99799b36d88cff8ab88dffc8e7 (diff)
downloadaspectj-d92319c43f5723d57887e09f2a839ee5b595fcfd.tar.gz
aspectj-d92319c43f5723d57887e09f2a839ee5b595fcfd.zip
Updates to better cope with future JDKs
The version handling in LangUtil has been overhauled to cope better with post 1.8 releases (JDK9 and JDK10 or 18.3 or whatever they call it). As part of this moved to treating JDK9 as '9' rather than '1.9'. Also removed duplicate version processing logic and had that defer to the one place in LangUtil where we now deal with it. Includes some generics tidyup in ajdoc. More ajdoc work is necessary for Java10 because it removes the standard doclet (old style). However trying to invoke the internal Javadoc handler in Java10 is failing due to module visibility rules.
Diffstat (limited to 'ajdoc/testsrc/org/aspectj')
-rw-r--r--ajdoc/testsrc/org/aspectj/tools/ajdoc/AjdocTestCase.java6
-rw-r--r--ajdoc/testsrc/org/aspectj/tools/ajdoc/CoverageTestCase.java2
2 files changed, 5 insertions, 3 deletions
diff --git a/ajdoc/testsrc/org/aspectj/tools/ajdoc/AjdocTestCase.java b/ajdoc/testsrc/org/aspectj/tools/ajdoc/AjdocTestCase.java
index afe288a3b..ea9a81875 100644
--- a/ajdoc/testsrc/org/aspectj/tools/ajdoc/AjdocTestCase.java
+++ b/ajdoc/testsrc/org/aspectj/tools/ajdoc/AjdocTestCase.java
@@ -198,8 +198,10 @@ public class AjdocTestCase extends TestCase {
!sourceLevel.equals("1.6") &&
!sourceLevel.equals("1.7") &&
!sourceLevel.equals("1.8") &&
- !sourceLevel.equals("1.9")) {
- fail("need to pass ajdoc '1.3' > '1.9' as the source level");
+ !sourceLevel.equals("1.9") &&
+ !sourceLevel.startsWith("9") &&
+ !sourceLevel.startsWith("10")) {
+ fail("need to pass suitable version to ajdoc as the source level");
}
if (inputFiles.length == 0) {
fail("need to pass some files into ajdoc");
diff --git a/ajdoc/testsrc/org/aspectj/tools/ajdoc/CoverageTestCase.java b/ajdoc/testsrc/org/aspectj/tools/ajdoc/CoverageTestCase.java
index 70aa02b22..af9ab0ed9 100644
--- a/ajdoc/testsrc/org/aspectj/tools/ajdoc/CoverageTestCase.java
+++ b/ajdoc/testsrc/org/aspectj/tools/ajdoc/CoverageTestCase.java
@@ -55,7 +55,7 @@ public class CoverageTestCase extends AjdocTestCase {
*/
public void testCoveragePublicMode() throws Exception {
File[] files = {file3,file9};
- runAjdoc("public","1.6",files);
+ runAjdoc("public","9",files);
// have passed the "public" modifier as well as
// one public and one package visible class. There