Skip to content

Add comprehensive unit tests#2

Open
akzj wants to merge 31 commits intomainfrom
add-comprehensive-unit-tests
Open

Add comprehensive unit tests#2
akzj wants to merge 31 commits intomainfrom
add-comprehensive-unit-tests

Conversation

@akzj
Copy link
Copy Markdown
Owner

@akzj akzj commented Jun 25, 2025

No description provided.

akzj and others added 30 commits June 16, 2025 11:46
1. Fixed ambiguous Conversation type by using specific imports
2. Modified database repository to handle missing database gracefully
3. Fixed SQLx query_as macro usage to avoid compile-time checks
1. Fixed repository links to use relative paths
2. Added Contributing section
3. Added links to LICENSE file
4. Improved overall documentation structure
1. Added StreamErrorResponse struct to cherrycore types
2. Implemented WebSocket handling for stream reading
3. Fixed AclChecker struct naming to follow Rust conventions
4. Added proper error handling for WebSocket connections
5. Added configuration file for streamserver
- Increased test count from 4 to 70 tests across streamstore and cherrycore crates
- Added comprehensive error handling tests for streamstore/errors.rs (3 tests)
- Added extensive entry encoding/decoding tests for streamstore/entry.rs (8 tests)
- Added thorough mem_table tests covering CRUD operations, concurrency, and validation (12 tests)
- Added complete table tests for data management, CRC, and multi-buffer handling (15 tests)
- Added JWT authentication tests for cherrycore/jwt.rs (11 tests)
- Added type serialization and HTTP response tests for cherrycore/types.rs (17 tests)
- Created test runner script (run_tests.sh) for easy test execution
- Added comprehensive testing documentation (TESTING.md)
- Fixed bugs discovered during testing (cap_remaining method in StreamData)
- Enhanced error handling and validation logic
- All tests passing with comprehensive coverage of core functionality

Test categories include:
- Happy path testing
- Error condition testing
- Edge case handling
- Concurrency testing
- Large data scenarios
- Serialization/deserialization
- Debug trait implementations
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.

2 participants