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

Refactor how the ClientServer works #47

Merged
merged 4 commits into from
Mar 24, 2023
Merged

Conversation

alcarney
Copy link
Member

The ClientServer object no longer automatically initializes or shutsdown the LSP session. It does however, still start and stop the client/server pair.

In fact, the ClientServer object shouldn't rely on anything LSP specific, which should open the door to using pytest_lsp to test any JSON-RPC based protocol in the future.

This means that fixture functions annotated with the @pytest_lsp.fixture decorator are now responsible for initializing and shutting down the LSP session, also granting the test author greater control over the initial setup.

The `ClientServer` object no longer automatically initializes or
shutdown the LSP session. It *does* however, still start and stop the
client/server pair.

In fact, the `ClientServer` object shouldn't rely on anything LSP
specific, which should open the door to using `pytest_lsp` to test any
JSON-RPC based protocol in the future.

This means that fixture functions annotated with the
`@pytest_lsp.fixture` decorator are now responsible for initializing
and shutting down the LSP session, also granting the test author
greater control over the initial setup.
@alcarney alcarney merged commit d04281d into swyddfa:develop Mar 24, 2023
@alcarney alcarney deleted the refactor branch March 24, 2023 19:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant