Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test with java 17 #234

Merged
merged 4 commits into from
Aug 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: Setup JDK
uses: actions/setup-java@v2
with:
java-version: 11
java-version: 17
distribution: 'adopt'

- name: Set up Maven
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,11 @@ Others papers about Nopol:

Nopol requires Java and an SMT solver installed on the machine (e.g. Z3)

Up to commit 80130c4c, Nopol required Java 8. Now it also works on Java 11, see https://github.com/SpoonLabs/nopol/pull/214
Java version:

* From 2013 to 2021, Nopol required Java 8.
* From Nov 19, 2021, Nopol works on Java 11, see https://github.com/SpoonLabs/nopol/pull/214
* From August 8 2024, Nopol works with Java 18, see https://github.com/SpoonLabs/nopol/pull/234

0) NoPol uses the `com.sun.jdi` that lives in `tools.jar`. Identify where `tools.jar` is and add the depencency in `pom.xml`

Expand Down
4 changes: 2 additions & 2 deletions nopol/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

To run the tests:

* install a JDK, and ensure that maven uses it
* install a JDK, see expected version in ../README.md, and ensure that maven uses it
* check that `z3` works well on the command line (`$ lib/z3/z3_for_linux``) (see TestUtility.java: private String solverPath = "lib/z3/z3_for_linux";)`
* first run `mvn test -DskipTests` in `../test-projects/`. This creates `../test-projects/target/test-classes` (but doesn(t run the tests since the examples are buggy)
* first run `mvn test -DskipTests` in `../test-projects/`. This creates `../test-projects/target/test-classes` (but doesn't run the tests since the examples are buggy)
* then `mvn test`
5 changes: 4 additions & 1 deletion nopol/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,10 @@
<artifactId>maven-surefire-plugin</artifactId>
<version>2.14.1</version>
<configuration>
<argLine>-Xms2048m -Xmx2048m -cp ${java.home.openjdk11}/jmods/jdk.jdi.jmod</argLine>
<!-- java.lang.RuntimeException: java.lang.reflect.InaccessibleObjectException: Unable to make abstract boolean com.sun.tools.jdi.ReferenceTypeImpl.isAssignableTo(com.sun.jdi.ReferenceType) accessible: module jdk.jdi does not "opens com.sun.tools.jdi" to unnamed module -->
<!-- java.lang.IllegalAccessError: class fr.inria.lille.repair.expression.value.Value$1 (in unnamed module @0x5577140b) cannot access class sun.reflect.generics.reflectiveObjects.NotImplementedException (in module java.base) because module java.base does not export sun.reflect.generics.reflectiveObjects to unnamed module @0x5577140b -->

<argLine>-Xms2048m -Xmx2048m -cp ${java.home.openjdk11}/jmods/jdk.jdi.jmod --add-opens jdk.jdi/com.sun.tools.jdi=ALL-UNNAMED --add-opens java.base/sun.reflect.generics.reflectiveObjects=ALL-UNNAMED</argLine>
</configuration>
</plugin>
<plugin>
Expand Down
Loading