Commit Graph

3 Commits

Author SHA1 Message Date
2eebc52f17 feat: wire relay API with dependency injection
- split settings module into per-struct files
- add DatabaseSettings with default in-memory SQLite path
- implement RelayApi struct with GET /relays and POST
  /relays/{id}/toggle
- wire create_relay_controller and create_label_repository into
  Application::build() with mock/real selection via cfg!(test) || CI
- register RelayApi in OpenApiService alongside existing APIs
2026-05-14 20:23:40 +02:00
4929266a8e style: format backend 2026-01-22 00:57:11 +01:00
e16e214b74 test(cors): write integration tests for CORS headers
Added 9 comprehensive integration tests covering:
- Preflight OPTIONS requests
- Actual requests with CORS headers
- Max-age header validation
- Credentials configuration
- Allowed methods configuration
- Wildcard origins
- Multiple origins
- Unauthorized origin rejection

All tests pass successfully.

Ref: T016
2026-01-22 00:57:11 +01:00