aboutsummaryrefslogtreecommitdiffstats
path: root/ajde.core/src/test
Commit message (Collapse)AuthorAgeFilesLines
* Add Java23 supportAndrew Clement2025-03-072-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The huge change with adopting Java23 is that 1.1 > 1.7 Java are now considered unsupported by Eclipse JDT, so the many thousands of tests we have that were specifying java versions lower than 1.8 were all failing with an unsupported version error. All those tests have had their versions bumped to 1.8.

That is why this commit includes so many changes. For example where we were specifying 1.5 - which was the case for many many generics/annotations tests, that is now 1.8. Also, some tests have been deleted because they make no sense now (verifying expected errors on Java 1.4 for example, errors that just can’t happen with minimum Java level 1.8). The biggest impact to tests was when bumping above 1.4 compliance suddenly there were 100s of adviceDidNotMatch messages. Some of these messages were actual indications of bad expectations in the test but many of them were just to-be-expected and were fixed either via an -Xlint:ignore option in the test spec or a SuppressAjWarnings in the test source.

One or two tests actually revealed real bugs that just didn’t surface with lower level java versions specified. A bare minimum of real Java 23 tests have been added just to get this sanity tested and committed. More would ideally be added. Other notable changes due to Eclipse JDT changes: org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/compiler/ast/*.java Changes in here because there are now more validations on the code generator methods we were calling. Now you can’t start manipulating variables without having declared them as proper local variables, so those extra calls to define them have been added.
 org.aspectj.ajdt.core/src/org/aspectj/org/eclipse/jdt/core/dom With needing to bump up the java versions, these classes had to be brought up to date with AST.JLS20 rather than only supporting versions 2/3. This was mostly copying patterns for the Eclipse classes.


* LangUtil: remove methods like 'is11VMOrGreater', 'is1dot5VMOrGreater'Alexander Kriegisch2024-02-191-1/+1
| | | | | | | | | | Replace them by a uniform method 'isVMGreaterOrEqual(double)', also overloaded for int. This gets rid of one 'AspectJ_JDK_Update' tag. One less place to check and update with each newly supported Java version. :-) Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Replace uses of StringBuffer with StringBuilder.Andrey Turbanov2021-11-202-2/+2
| | | | StringBuffer is a legacy synchronized class. StringBuilder is a direct replacement to StringBuffer which generally have better performance.
* Upgrade license from CPLv1/EPLv1 to EPLv2Alexander Kriegisch2021-06-0420-134/+134
| | | | | | | This was required by the Eclipse team as one precondition for the next release. Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Fix 'ajdoc' tests for Java 15 buildAlexander Kriegisch2021-03-141-8/+8
| | | | Signed-off-by: Alexander Kriegisch <Alexander@Kriegisch.name>
* Merge branch 'master' into feature/collection-performanceAndy Clement2020-08-151-1/+0
|\
| * Cleanup unused importsLars Grefer2020-08-161-1/+0
| | | | | | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* | Redundant Collection.addAll() callLars Grefer2020-08-151-2/+1
|/ | | | | | Reports Collection.addAll() and Map.putAll() calls after instantiation of a collection using a constructor call without arguments. Such constructs can be replaced with a single call to a parametrized constructor which simplifies code. Also for some collections the replacement might be more performant. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* lets have maven fail if those tests fail...Andy Clement2020-08-143-32/+46
|
* Merge branch 'master' of github.com:eclipse/org.aspectj into ↵Lars Grefer2020-08-146-102/+104
|\ | | | | | | remove-old-version-checks
| * Fix up tests and reduce verbosity on J11Andy Clement2020-08-146-102/+104
| |
* | Remove checks for old Java VersionsLars Grefer2020-08-131-2/+0
|/ | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Use the diamond operator where possibleLars Grefer2020-08-1312-47/+47
| | | | Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* 'String.indexOf()' expression is replaceable with 'contains()'Lars Grefer2020-08-084-8/+8
| | | | | | Reports any String.indexOf() expressions which can be replaced with a call to the String.contains() method available in Java 5 and newer. Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* 'for' loop replaceable with enhanced 'for' loopLars Grefer2020-08-088-34/+28
| | | | | | Reports for loops which iterate over collections or arrays, and can be replaced with an enhanced for loop (i.e. the foreach iteration syntax). Signed-off-by: Lars Grefer <eclipse@larsgrefer.de>
* Add module tests back in - but streamlinedAndy Clement2019-01-311-0/+56
|
* mavenizing ajde.core - doneAndy Clement2019-01-2919-0/+3694