swagger-test-0.1.0: Testing of Swagger APIs

Copyright(c) Rodrigo Setti 2017
LicenseBSD3
Maintainerrodrigosetti@gmail.com
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Test.Swagger.Validate

Description

Exposes some functions to validate responses against a Swagger schema. There are four functions that can be used depending whether the response is parsed, if the operation is available (or just the id)

Synopsis

Documentation

parseResponse :: ByteString -> Either String HttpResponse Source #

Parse a HttpResponse from ByteString

validateResponseBytes :: ByteString -> Swagger -> OperationId -> Either String () Source #

Validate a response, from a particular operation id, (encoded in a byte-string) against a Swagger schema

validateResponseWithOperation :: HttpResponse -> Swagger -> Operation -> Either String () Source #

Validate a response, from a particular operation against a Swagger schema

validateResponse :: HttpResponse -> Swagger -> OperationId -> Either String () Source #

Validate a response, from a particular operation id against a Swagger schema