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

feat: Gradle 2.x plugin SDK-based build #783

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

sbouchet
Copy link
Contributor

may close #761

@angelozerr
Copy link
Contributor

@SCWells72 there are several tests with Java LS which fail, have you some idea?

@SCWells72
Copy link
Contributor

@SCWells72 there are several tests with Java LS which fail, have you some idea?

Not sure. I believe tests passed 100% on my branch, but obviously lots of changes were needed to get it into proper shape.

I'll be happy to check out this branch tomorrow after I get my own release out and investigate if it's not resolved by then.

@sbouchet sbouchet marked this pull request as ready for review February 10, 2025 09:38
@angelozerr
Copy link
Contributor

@sbouchet could you resolve conflicts please.

It seems CI build is failling. What is the status of this PR?

@sbouchet
Copy link
Contributor Author

unit tests are failling but i don't have enough knowledge to debug/fix.
i can spot that for example formatting test when parameter is disabled does fails.
below the list of failures :

image

@sbouchet
Copy link
Contributor Author

note that the preleminary work done by scott also failed, but with only one failure:
https://github.com/redhat-developer/lsp4ij/actions/runs/12918289698/job/36026492082

@angelozerr
Copy link
Contributor

@SCWells72 could you help us to fix those tests please?

@SCWells72
Copy link
Contributor

@SCWells72 could you help us to fix those tests please?

The issue with these Java-specific tests is that they register the extension *.java and create test files with that extension, but of course IntelliJ IDEA itself has first-class support for Java and is superseding LSP4IJ when those files. Evidently in 2023.2, that wasn't a problem, but in 2023.3 against which the new branch is running, the native Java language support is causing these failures.

I was able to work around this with some of them by changing the extension to .javax, but there are still some failures that I'm investigating now.

There's one other failure in BootstrapPropertiesCompletionTest that may be caused by a similar conflict with the IDE's first-class support for *.properties files, but I haven't confirmed that yet.

@angelozerr
Copy link
Contributor

Ok a simple fix is to rename .java to .myjava

@SCWells72
Copy link
Contributor

Ok a simple fix is to rename .java to .myjava

That doesn't quite work. That's pretty much what I did by changing the extension to javax, and it left some failures. I have a fix now that actually removes the file type association for *.java in setUp() and restores it in tearDown(). That fixes all but one folding test, at least on the Java side. But I should have fixes for most if not all of these shortly.

@SCWells72
Copy link
Contributor

SCWells72 commented Feb 11, 2025

Okay, I've addressed the Java-specific failures. I confess that I'm not sure how to contribute changes to another user's PR branch, so here are the modified files:

pr_783_test_fixes.zip

Removing/restoring the file type association worked perfectly for the on-type formatting tests but not for the folding range tests, and vice-versa for the folding range tests, hence why there are two different solutions in these changes.

This leaves only remaining failure in BootstrapPropertiesCompletionTest.testCompletionOnPropertyValueWithValueAtEnd(). @angelozerr, it looks like you've been the author of that one and its associated base classes, so hopefully you can figure that one out which would get tests back to 100% on this branch.

@sbouchet sbouchet added the build label Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 📝 In Progress
Development

Successfully merging this pull request may close these issues.

3 participants