Compact .NET API automation example built with NUnit and HttpClient against public NASA endpoints.
This repository is a small QA automation project that demonstrates:
- request construction through shared value objects
- JSON response validation
- basic status-code assertions
- reusable helpers for fixture-based comparisons
It is not a full framework, but a compact public sample of API-focused test organization in C#.
- APOD endpoint checks
- Mars weather endpoint checks
- response field validation against expected JSON values
- simple reusable helper and model structure
C#.NET 6NUnitHttpClientSystem.Text.JsonNewtonsoft.Json
TestsApi/TestsApi/ApiTests/test classesTestsApi/TestsApi/Models/response modelsTestsApi/TestsApi/Helpers/JSON helpers and shared logicTestsApi/TestsApi/JsonFiles/expected comparison valuesTestsApi/TestsApi/Values/base URLs, routes, and API key access
Set an API key if you want to use your own:
$env:NASA_API_KEY="your_api_key"Then run:
dotnet test .\TestsApi\TestsApi\TestsApi.csprojIf NASA_API_KEY is not set, the project falls back to DEMO_KEY.
- Public APIs can change behavior over time, so some assertions may need refreshes
- This repo is meant as a small public sample, not as a production-grade enterprise framework