Yeah, we have TestRoute. It has one issue though: It doesn't have support for passing a custom context. One option is to extend the method with yet argument but since it already has 9 (!!!), this seems like a huge mess. Therefore, I decided to invent a new small library for writing API tests. It uses structs heavily which means that adding features to it doesn't mean changing 100 lines of code (like adding another arg to TestRoute does). I hope that we can start using this library more in our tests as it was designed to be very flexible and powerfule. Signed-off-by: Ondřej Budai <ondrej@budai.cz> |
||
|---|---|---|
| .. | ||
| apicall.go | ||
| helpers.go | ||
| request.go | ||
| validator.go | ||