-
Notifications
You must be signed in to change notification settings - Fork 35
A new test framwork with a ULSP test suite #540
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
Draft
Jafaral
wants to merge
5
commits into
uniconproject:master
Choose a base branch
from
Jafaral:ulsp-testing
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
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
ab4b7ac to
a5847c9
Compare
7cc531e to
fab9f82
Compare
Collaborator
|
Perhaps it makes sense to defer a review until the CI runs without errors -- either because the underlying cause of the CI failures have been fixed, or the ULSP tests are explicitly disabled for the configurations that currently fail. |
Signed-off-by: Jafar Al-Gharaibeh <[email protected]>
Signed-off-by: Jafar Al-Gharaibeh <[email protected]>
58306ef to
60be717
Compare
Add a complete test suite for the Unicon Language Server Protocol (ULSP) implementation with four main test categories: 1. JSON-RPC Tests (jsonrpc_test.icn) - Tests JSON-RPC protocol with calculator server - Validates concurrent request handling - Tests basic arithmetic operations 2. LSP Message Tests (lsp_message_test.icn) - Tests JSON-RPC message parsing and validation - Tests all LSP request/response message types - Tests notification handling - Tests error handling and malformed message rejection 3. LSP Feature Tests (lsp_feature_test.icn) - Tests LSP features with realistic Unicon code - Tests completion, hover, definition, symbols, formatting, folding - Tests signature help functionality - Uses LSPDB for symbol information 4. LSP Protocol Tests (lsp_protocol_test.icn) - Integration tests with actual server-client communication - Tests server initialization and capability negotiation - Tests document synchronization (didOpen, didChange, didSave) - Tests end-to-end LSP feature workflows Unified Test Runner (lsp_run_tests.icn): - Executes all four test suites sequentially - Aggregates test counts from all suites - Provides comprehensive test reporting - Supports individual test suite execution Test Framework Features: - Expected result capture mode with JSON output - Deep comparison for expected vs actual results - JSON-formatted error reporting - Consistent test structure across all test files - Proper Unicon success/failure semantics Makefile Integration: - Individual test targets for each test suite - Unified test runner target - Clean targets for test artifacts All test files follow consistent structure: - Test class with run_all_tests() method - Global counters for test tracking - Standalone execution support via $ifdef STANDALONE
Signed-off-by: Jafar Al-Gharaibeh <[email protected]>
Signed-off-by: Jafar Al-Gharaibeh <[email protected]>
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.
Add a complete test suite for the Unicon Language Server Protocol (ULSP)
implementation with four main test categories:
JSON-RPC Tests (jsonrpc_test.icn)
LSP Message Tests (lsp_message_test.icn)
LSP Feature Tests (lsp_feature_test.icn)
LSP Protocol Tests (lsp_protocol_test.icn)
Unified Test Runner (lsp_run_tests.icn):
Test Framework Features:
Makefile Integration:
All test files follow consistent structure: