Skip to content

Checking for null capabilities.#7921

Merged
lahodaj merged 1 commit intoapache:masterfrom
lahodaj:capabilities-can-be-null
Oct 29, 2024
Merged

Checking for null capabilities.#7921
lahodaj merged 1 commit intoapache:masterfrom
lahodaj:capabilities-can-be-null

Conversation

@lahodaj
Copy link
Copy Markdown
Contributor

@lahodaj lahodaj commented Oct 29, 2024

We unfortunately broke the ServerTest with:
#7750

This patch tries to account for capabilities that are null. I believe client.getNbCodeCapabilities() never returns null, but client.getNbCodeCapabilities().getClientCapabilities() does, currently.

@lahodaj lahodaj added Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form) LSP [ci] enable Language Server Protocol tests VSCode Extension labels Oct 29, 2024
@lahodaj lahodaj added this to the NB25 milestone Oct 29, 2024
@sid-srini
Copy link
Copy Markdown
Contributor

Thank you so much.

sid-srini added a commit to sid-srini/javavscode that referenced this pull request Oct 29, 2024
… only

Backported apache/netbeans#7921 to fix unit tests breakage due to uninitialised
`NbCodeClientCapabilities.getClientCapabilities()` by adding a null check in the
initialisation of `lineFoldingOnly` in `TextDocumentServiceImpl.foldingRange()`.

Signed-off-by: Siddharth Srinivasan <siddharth.srinivasan@oracle.com>
@lahodaj lahodaj merged commit 2eecf2a into apache:master Oct 29, 2024
@lahodaj
Copy link
Copy Markdown
Contributor Author

lahodaj commented Oct 29, 2024

Thanks for the review!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Java [ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form) LSP [ci] enable Language Server Protocol tests VSCode Extension

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants