mirror of
https://github.com/saymrwulf/alpha-arena.git
synced 2026-11-17 06:20:38 +00:00
docs: update TESTING.md with new test files and integration tests
- Add test_integration.py, test_debate.py, test_signals.py, test_llm_providers.py to structure - Add Integration Tests section documenting multi-agent testing - Update test count to 328+
This commit is contained in:
parent
b627b4319a
commit
435e09f732
1 changed files with 28 additions and 1 deletions
|
|
@ -39,6 +39,10 @@ tests/
|
|||
├── conftest.py # Shared fixtures and configuration
|
||||
├── test_api.py # API endpoint tests
|
||||
├── test_e2e.py # End-to-end functional tests
|
||||
├── test_integration.py # Multi-agent integration tests (NEW)
|
||||
├── test_debate.py # Debate system tests (NEW)
|
||||
├── test_signals.py # Signal aggregation tests (NEW)
|
||||
├── test_llm_providers.py# LLM provider tests (NEW)
|
||||
├── test_risk.py # Risk management unit tests
|
||||
├── test_pnl.py # PnL accounting unit tests
|
||||
├── test_indicators.py # Technical indicator tests
|
||||
|
|
@ -47,6 +51,8 @@ tests/
|
|||
└── test_core_types.py # Core type tests
|
||||
```
|
||||
|
||||
**Test count: 328+ tests**
|
||||
|
||||
## Test Categories
|
||||
|
||||
### Unit Tests
|
||||
|
|
@ -103,9 +109,30 @@ async def test_health_check(async_client):
|
|||
assert response.json()["status"] == "healthy"
|
||||
```
|
||||
|
||||
### Integration Tests
|
||||
|
||||
Test multi-component integration with mocked LLM providers.
|
||||
|
||||
```bash
|
||||
pytest -m "integration"
|
||||
```
|
||||
|
||||
**What's tested:**
|
||||
- Full agent coordination (Research → Risk → Debate → Execution)
|
||||
- Multi-agent debate with multiple personas
|
||||
- Confidence calibration tracking
|
||||
- Signal aggregation from multiple sources
|
||||
- Event calendar impact on trading
|
||||
- End-to-end trading cycle with mocked broker
|
||||
- Risk rejection scenarios
|
||||
- LLM failure handling
|
||||
- Performance metrics tracking
|
||||
|
||||
**Key fixture:** `MockLLMProvider` - Returns structured JSON responses matching the real `LLMResponse` interface.
|
||||
|
||||
### End-to-End Tests
|
||||
|
||||
Test complete user workflows.
|
||||
Test complete user workflows via API.
|
||||
|
||||
```bash
|
||||
./scripts/test.sh e2e
|
||||
|
|
|
|||
Loading…
Reference in a new issue