GithubHelp home page GithubHelp logo

bgonibeedu / restapitesting.framework.cheetah Goto Github PK

View Code? Open in Web Editor NEW

This project forked from programmingwithbangal/restapitesting.framework.cheetah

0.0 0.0 0.0 2.51 MB

This is a RESTful API testing Framework using C#, .NET Core, xUnit, Specflow, HttpClient and Fluent Assertions to test JSONPlaceholder REST API.

C# 63.62% Gherkin 36.38%

restapitesting.framework.cheetah's Introduction

RestApiTesting.Framework.Cheetah

This is a RESTful API testing Framework using C#, .NET Core, xUnit, Specflow BDD test framework, HttpClient and Fluent Assertions to test JSONPlaceholder REST API.

Specflow

Use SpecFlow to define, manage and automatically execute human-readable acceptance tests in .NET projects. Writing easily understandable tests is a cornerstone of the BDD paradigm and also helps build up a living documentation of your system. https://specflow.org/

Target framework

.NET Core 2.1

JSONPlaceholder

JSONPlaceholder is a free online REST API that you can use whenever you need some fake data. It's great for tutorials, testing new libraries, sharing code examples. https://jsonplaceholder.typicode.com/

Routes Tested

The following HTTP methods are tested:

  • GET
  • POST
  • PUT
  • PATCH
  • DELETE

HttpClient

HttpClient class provides a base class for sending/receiving the HTTP requests/responses from a URL. It is a supported async feature of .NET framework. HttpClient is able to process multiple concurrent requests. It is a layer over HttpWebRequest and HttpWebResponse. All methods with HttpClient are asynchronous. https://docs.microsoft.com/en-us/uwp/api/windows.web.http.httpclient

Assertions

Fluent Assertions is used for validation. https://fluentassertions.com/

Integrated Development Environment

Microsoft Visual Studio IDE is used to develop this Framework.

Visual Studio Extensions

  • Extensions => Manage Extensions => Search and Install SpecFlow for Visual Studio

Build Solution

  • Build => Build Solution

Run Tests

  • Test => Windows => Test Explorer => Run All

Run Tests with Command Prompt/Windows PowerShell

  • Open Folder in File Explorer: ..\RestApiTesting.Framework.Cheetah\bin\Debug\netcoreapp2.1
  • Open Command Prompt/Windows PowerShell
  • Run "dotnet vstest RestApiTesting.Framework.Cheetah.dll"

restapitesting.framework.cheetah's People

Contributors

programmingwithbangal avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.