Skip to content

BurhanH/automaton-v23

Repository files navigation

automaton-v23

Automation testing framework (API) - an example. Based on C#, .Net8, MSTest, Refit

GitHub Tests

This testing framework to test REST API for https://jsonplaceholder.typicode.com. Simple calls like GET, PATCH, DELETE.

Requirements

.Net8, Refit 8.0.0,
MSTest

Project structure

-- automaton-v23
   `-- .github
       `-- workflows
           |-- dotnet.yml
   |-- .dockerignore
   |-- .gitignore
   |-- ApiTest.cs
   |-- AutomatonV23.csproj
   |-- AutomatonV23.sln
   |-- Dockerfile
   |-- GlobalUsings.cs
   |-- IApiClient.cs
   |-- LICENSE
   |-- PostCommentResponse.cs
   |-- PostResponse.cs
   |-- README.md

Documentation and Distributives

  1. C#
  2. .Net
  3. MSTest
  4. Refit
  5. Docker
  6. GitHub Actions

How to run tests

dotnet test
dotnet test --verbosity normal
dotnet test --logger:"console;verbosity=detailed"

Docker test and build

docker build -t test-docker .

Docker runs an image with all tests

docker run test-docker

Docker runs an image with all tests and specified logger

docker run test-docker /logger:console;verbosity=normal

Docker runs an image with specified tests

docker run test-docker /Tests:TestGetPosts,TestGetPostComments

Docker test and build sample

Docker-test-and-build-automatonV23.mp4

About

Automation testing framework (API) based on Refit

Topics

Resources

License

Stars

Watchers

Forks