Questions tagged [dredd]

Dredd is a command-line tool for testing API documentation written in API Blueprint format against its backend implementation.

From the github page of dredd:

Dredd is a command-line tool for testing API documentation written in API Blueprint format against its backend implementation. With Dredd you can easily plug your API documentation into the Continous Integration system like Travis CI or Jenkins and have API documentation up-to-date, all the time. Dredd uses the Gavel for judging if a particular API response is valid or if is not. If you are curious about how decisions are made, please refer to Gavel's behavior specification.

60 questions
0
votes
1 answer

dredd fails to run with errors 'Data does not match any schemas from 'anyOf' and such more

Trying to run dredd on swagger documentation. Dredd fails with next errors: - error: API description parser error in /albums.json:266 (from line 266 column 10 to column 21): Data does not match any schemas from 'anyOf' - error: API description…
slim1979
  • 28
  • 4
0
votes
1 answer

Validating openapi 3.0 API description against backend implementation of the API in Loopback 4

I tried Dredd but it's not working with openapi spec 3.0 that is generated by Loopback 4 framework. I wanted to know what are the options available for this type of testing where I want to validate the openapi 3.0 API description against backend…
VISHAL DAGA
  • 3,616
  • 8
  • 41
  • 50
0
votes
1 answer

Openapi3 and CSV response (for Dredd)

I test my Api with DREDD against it's specification (written in Openapi3 considering, painfull limitations of Support by Dredd considered). No I have one endpoint, which produces CSV-data if the Accept-header is set so. '/my-endpoint': …
Paflow
  • 1,581
  • 19
  • 43
0
votes
1 answer

What is best practice to test error responses with Dredd?

I want to describe my existing API with openapi 3 and prove my description with dredd. I know openapi 3 implementation is experimental, but I don't use any of the elements which are not supported yet. This is part of my spec.yaml paths: /login: …
Paflow
  • 1,581
  • 19
  • 43
0
votes
0 answers

Dredd - Getting error when parsing swagger file 'API description parser warning in'

I've recently upgraded Dredd from version 4.8 to 8+, and started getting the dozens of theses errors when Dredd attempts to parse the Swagger and generate the transaction request body. Each error is about a different row in the swagger file. warn:…
David Faizulaev
  • 2,471
  • 13
  • 42
  • 78
0
votes
1 answer

Raise Warning in Hook?

Is it possible to raise a Warning message within a hook function? I can log a message with hook.log() but would like it to be properly handled as loglevel 'warning'. hooks.log("WARNING: Something unusual has happened")
TrickiDicki
  • 125
  • 2
  • 12
0
votes
1 answer

Dredd: Ruby-hooks: execute same hook for multiple requests

The problem I'm facing is: I have a request and need to check 3 types of responses for this request. Each time I need to slightly modify my request body before sending it. dredd --names: info: Users > User Operations > Update User > Example 1 skip:…
Dimu4
  • 163
  • 2
  • 16
0
votes
1 answer

How to exclude a test from appearing in the documentation

I'm working with Dredd the HTTP API Testing Framework to test my backend apis. Well the idea is that each time you create a test case a documentation will be generated automatically which is a good practice to ensure that documentation is always up…
larnouch
  • 169
  • 13
0
votes
1 answer

Dredd Apiary contract driven test - Is there any way to access private apiary documentation blueprint format from local dredd config?

I'm running contract driven development tests using dredd. I know how to configure dredd tests to run either against a local or remote server, given a blueprint apib file. Typically, the relevant fields in my dredd config file will read…
0
votes
1 answer

Swagger-Dredd: specifying more than one type for a parameter

I am trying to implement API testing in my project and i am using Dredd. Now some of my response parameters return 'null' value and that is okay according to logic. In my yml file, how do i specify that null can be a valid value apart from the…
nirav vyas
  • 11
  • 5
0
votes
2 answers

Dredd Api Blueprint for text format

There is an api blueprint dredd test problem which bothers me for a while. I can dredd test json format successed, but for text format, it always be failed. The fail message -> fail: body: Real and expected data does not match. But I check the…
Rong.lin
  • 1
  • 2
0
votes
1 answer

can we connect to public api endpoint instead of local host using dredd tool?

I tried to use a public end point(eg:api.openweathermap.org/data/2.5/weather?lat=35&lon=139) instead of the local host while configuring dredd and ran the command to run the tool.But I am not able to connect to the end point through dredd. It is…
sachu
  • 1
  • 1
0
votes
1 answer

How can I use a dredd docker image interactively?

I would like to use this docker container apiaryio/dredd instead of the npm package dredd. I am not familiar with running and debugging npm based docker images. How can I run the basic usage example of the npm package "Quick Start" section $ dredd…
thinwybk
  • 2,493
  • 16
  • 40
0
votes
1 answer

npm install -g dredd seems to instal but dredd not working

I've installed dredd globally on mac os but when calling dredd it comes back command not found ➜ test git:(master) dredd zsh: command not found: dredd Not sure if this is being saved in the correct place or there's an extra step i'm missing. My…
0
votes
1 answer

Multiple requests with dredd yml

Using node dredd against my API. I opted for using yml file as this is a std that is familiar with my team. Here is an example snippet we have functioning correctly: /api/station/{id}: get: produces: - application/json;…
John
  • 4,512
  • 8
  • 48
  • 98