langflow/src/backend/tests
Edwin Jose b093c1fadb
refactor(session): migrate to server-based session management and add tests (#9077)
* update MCP Tests

* [autofix.ci] apply automated fixes

* Update util.py

* [autofix.ci] apply automated fixes

* Refactor MCP session manager for better configurability and cleanup (#9176)

* Add log rotation and header validation features

Introduces support for log rotation via the LANGFLOW_LOG_ROTATION environment variable and CLI/config options, with documentation updates. Adds header validation and sanitization for MCP connections, ensuring RFC 7230 compliance and security. Frontend and backend now support passing custom headers for MCP servers. Includes extensive new and updated unit tests for header handling, MCP utilities, and log rotation.

* Add unit tests for MCP utilities and update disconnect logic

Added comprehensive unit tests for MCP utility functions, session management, header validation, and client classes in test_mcp_util.py. Updated MCPStdioClient and MCPSseClient disconnect methods for clearer session cleanup logic. Refactored test_mcp_component.py to remove redundant and duplicated tests, consolidating coverage in the new test suite.

* [autofix.ci] apply automated fixes

* Update test_mcp_memory_leak.py

* Update util.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2025-08-09 09:30:39 +00:00
..
data feat: combine chat history and chat store into a CRUD component (#8323) 2025-06-05 22:19:01 +00:00
integration refactor(session): migrate to server-based session management and add tests (#9077) 2025-08-09 09:30:39 +00:00
locust refactor(tests): parameterize template tests and update timeout use (#9224) 2025-07-29 22:32:48 +00:00
performance tests: Remove unnecessary benchmark markers from server init tests (#5806) 2025-01-20 16:43:46 +00:00
unit refactor(session): migrate to server-based session management and add tests (#9077) 2025-08-09 09:30:39 +00:00
.test_durations chore: update test durations (#8550) 2025-06-16 11:05:18 -03:00
__init__.py refactor: improve maintainability and testability of Vertex.build_params (#5808) 2025-03-11 15:34:15 +00:00
api_keys.py ref: Auto-fix ruff rules in tests (#4154) 2024-10-16 15:42:36 +00:00
base.py fix: make sure tests run async (#5842) 2025-01-21 08:16:33 -08:00
conftest.py refactor(tests): parameterize template tests and update timeout use (#9224) 2025-07-29 22:32:48 +00:00
constants.py chore: Update supported versions in tests constants (#5569) 2025-01-07 15:43:49 +00:00