mirror of
https://github.com/azaion/satellite-provider.git
synced 2026-06-22 16:31:15 +00:00
[AZ-285] Test infrastructure: scaffold unit test project + fixtures
- Add SatelliteProvider.DataAccess project reference to test csproj
(enables mocking ITileRepository / IRegionRepository / IRouteRepository)
- Replace DummyTest placeholder with InfrastructureTests covering:
* All mockable interfaces (ISatelliteDownloader, repos, queue, services)
can be mocked via Moq
* TileService can be constructed with mocked dependencies
* Test coordinate fixtures load with expected values
- Add Fixtures/TestCoordinates.cs with REG-01..REG-03 + ROUTE-01/04/06
shared test data
- Archive AZ-285 to _docs/02_tasks/done/
- Batch 1 review report: PASS_WITH_WARNINGS (Low/Spec-Gap deferred AC-2,
Low/Maintainability pre-existing FluentAssertions 8.x license note)
Verification: docker dotnet test run — 4/4 tests pass in 2.35s.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
# Test Infrastructure
|
||||
|
||||
**Task**: AZ-285_test_infrastructure
|
||||
**Name**: Test Infrastructure: scaffold unit test project with mocks
|
||||
**Description**: Scaffold the unit test project with proper mocking infrastructure for ISatelliteDownloader and all repository interfaces
|
||||
**Complexity**: 3 points
|
||||
**Dependencies**: None
|
||||
**Component**: Blackbox Tests
|
||||
**Tracker**: AZ-285
|
||||
**Epic**: AZ-284
|
||||
|
||||
## Scope
|
||||
|
||||
- Replace DummyTest with actual test infrastructure in `SatelliteProvider.Tests`
|
||||
- Add Moq package for interface mocking (ISatelliteDownloader, ITileRepository, IRegionRepository, IRouteRepository, IRegionRequestQueue)
|
||||
- Add shared test fixtures with standard test coordinates (47.461747, 37.647063 for tiles; 48.276067, 37.384458 for routes)
|
||||
- Verify existing docker-compose.tests.yml works as integration test environment
|
||||
- Ensure FluentAssertions is available (already in project)
|
||||
|
||||
## Test Project Layout
|
||||
|
||||
Existing structure is sufficient — enhance `SatelliteProvider.Tests/`:
|
||||
- Add `Fixtures/` for shared test data
|
||||
- Add test classes per service (TileServiceTests, RegionServiceTests, RouteServiceTests)
|
||||
|
||||
## Acceptance Criteria
|
||||
|
||||
**AC-1**: Unit test project builds and all mock interfaces resolve
|
||||
**AC-2**: `docker-compose -f docker-compose.yml -f docker-compose.tests.yml up --build --abort-on-container-exit` succeeds
|
||||
**AC-3**: Test runner discovers and executes test classes
|
||||
Reference in New Issue
Block a user