https://github.com/abhisheksoni27/wilson
Quickly write tests for APIs using JSON configs
https://github.com/abhisheksoni27/wilson
api golang json no-code testing
Last synced: about 2 months ago
JSON representation
Quickly write tests for APIs using JSON configs
- Host: GitHub
- URL: https://github.com/abhisheksoni27/wilson
- Owner: abhisheksoni27
- Created: 2021-02-12T14:33:50.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2021-02-13T13:55:06.000Z (over 5 years ago)
- Last Synced: 2025-03-12T20:42:50.267Z (over 1 year ago)
- Topics: api, golang, json, no-code, testing
- Language: Go
- Homepage:
- Size: 18.6 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# wilson
**wilson** - quickly write tests for APIs using JSON configs
If you want to quickly write tests for your APIs and, then `wilson` is the tool for you.
Defining what your APIs do on different inputs shouldn't be that hard. All it takes is some info about the parameters, or request body, and what to expect in the response (along with data types).
Here's an example `wilson` config for the `https://www.thecolorapi.com/id`
```
[
{
"url": "https://www.thecolorapi.com/id",
"type_of_request": "get",
"expected_status_code": 200,
"request_params": {
"hex": "00ff00"
},
"expected_response": {
"hex": {
"value": "String",
"clean": "String"
}
}
}
]
```
# Installation
```
go get github.com/abhisheksoni27/wilson
```
This will install the `wilson` command in your `GOBIN`
# Usage
wilson [command]
### Available Commands
`help` Help about any command
`run` run all tests in config directory
### The run command
run all tests in config directory
**Usage:**
```
wilson run [flags]
```
**Flags:**
`-c, --config` **string** _config directory (default is $HOME/.wilson/)_
`-m, --max-tests-at-a-time` **int** _max-tests-at-a-time number of tests to run in parallel (default 4)_