Service | Status |
---|---|
GitHub | |
CircleCI | |
SonarCloud |
This project contains C# integration tests for the Airport Gap API built using NUnit. The tests demonstrate:
- A reusable HTTP client framework with support for authenticated and unauthenticated requests
- FluentAssertions for expressive and maintainable assertions
- Continuous Integration via Github Actions, CircleCI and static code analysis with SonarCloud
- .NET 9 SDK or later
- A valid Airport Gap API token set as an environment variable for authenticated tests (see below)
- Clone the repository:
git clone https://github.com/BrandonNaidoo/airportgap-apiintegration-tests.git cd airportgap-apiintegration-tests
- Set the API token environment variable:
On Windows (PowerShell):
On macOS/Linux:
$env:AIRPORT_GAP_API_TOKEN = "your_api_token_here"
export AIRPORT_GAP_API_TOKEN=your_api_token_here
- Restore dependencies and build:
dotnet restore dotnet build
Run all tests using the .NET CLI:
dotnet test
This will execute the NUnit tests, using the API token from the environment variable for authenticated requests where applicable.
Integration-tests/
Framework/
— HTTP client, factories, request/response buildersModels/
— Request and response data modelsTests/
— NUnit test classes organized by API features
.circleci/
— CircleCI configuration for CI pipelinesREADME.md
— This documentation
- GitHub Actions and CircleCI are both configured to run integration tests on push and pull request events
- SonarCloud provides code quality and coverage reports, linked in the badges above
- Tests enforce code style via .NET analyzers and run with FluentAssertions for clarity
At this time, this project is not open to external contributions.
Please feel free to fork the repository for personal use or experimentation, but I am not currently accepting pull requests or feature suggestions.
This project is licensed under the MIT License.
Thanks to Dev Tester for providing a publicly Api for testing.