test: strengthen inline doc-sync ordering coverage for issue #9#18
Merged
Conversation
- Update tests/documents.rs Mirror test to simulate the dispatcher's inline open before invoking the handler, so it exercises ADR 0003 2026-06-15 addendum semantics rather than opening the document inside the handler. - Add two_did_change_mutations_apply_in_receipt_order to tests/doc_sync_ordering.rs, verifying that consecutive incremental edits compose in receipt order and are visible to the next request.
5298481 to
a9f7f62
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #9.
The core dispatcher change for issue #9 — applying the built-in state mutation for
textDocument/didOpen,didChange,didClose, anddidSaveinline in the read-loop and keeping user-side reactions on spawned tasks — is already onmain(seesrc/dispatcher.rsand the ADR 0003 2026-06-15 addendum).This PR strengthens the test coverage around that behavior:
tests/documents.rs: updates theMirrortest to simulate the dispatcher's inline open before invoking the handler, so it exercises the inline-mutation semantics rather than opening the document inside the handler.tests/doc_sync_ordering.rs: addstwo_did_change_mutations_apply_in_receipt_order, verifying that consecutive incremental edits compose in receipt order and that the resulting document is visible to the next request.cargo testandcargo clippy --all-targets --all-featurespass locally.