Arjun Mahishi
ecdde720b4
http_assertions: honour the msgAndArgs provided with each assertion
2024-02-23 00:16:29 +05:30
hidu
ce5c2b684b
assert: fix httpCode and HTTPBody occur panic when http.Handler read body
2023-10-15 23:34:32 +02:00
Olivier Mengué
af4d8a66cf
Merge pull request #1320 from lesichkovm/patch-1
...
Fix adding ? when no values passed
2023-07-11 22:52:16 +02:00
Harald Nordgren
4c93d8f201
EqualExportedValues: Handle nested pointer, slice and map fields ( #1379 )
...
* EqualExportedValues: Handle pointer and slice fields
* Update assert/assertions.go
Co-authored-by: Michael Pu <michael.pu123@gmail.com>
* Reduce redundant calls to 'copyExportedFields'
* Update comments
* Add support for maps
* Update Go version support to 1.19 and onward
* Re-generate after rebasing
---------
Co-authored-by: Michael Pu <michael.pu123@gmail.com>
2023-05-11 07:42:04 +10:00
Milan Lesichkov
c029f419b8
Fix adding ? when no values passed
2022-12-22 10:45:24 +00:00
Boyan
3184a9e141
This reverts commit 0a813b5898
.
2020-06-05 20:47:15 +10:00
Boyan
6353e56395
This reverts commit 9d083cac4a
.
2020-06-05 20:47:15 +10:00
gohargasparyan
9d083cac4a
go format
2020-05-04 07:47:34 +10:00
gohargasparyan
0a813b5898
allow body for HTTPBodyContains and HTTPBodyNotContains for POST
2020-05-04 07:47:34 +10:00
Martijn
bb468cc94d
Remove unneeded return statements
2020-04-06 07:42:56 +10:00
Martijn
f0828adbb3
Add HTTPStatusCode assertion
...
Allows for asserting a specific HTTP status code was returned instead of a general success, error or redirect assertion.
2020-04-06 07:42:56 +10:00
Stephan Renatus
adc03609b3
http_assertions: fix docs (missing methods)
...
Signed-off-by: Stephan Renatus <srenatus@chef.io>
2018-06-09 12:51:17 +01:00
Dinesh Kumar
6efb0c49fb
Adding url.Values to request RawQuery, fixes 522
2018-03-18 18:57:06 +00:00
Ernesto Jiménez
a726187e31
Fix vim-go integration and other editors
...
Use Go 1.9 t.Helper() to remove testify from the output of the tests and
stop using `\r` to try to overwrite the output.
This means in Go 1.7 and Go 1.8 testify will appear as failing the test.
2018-02-02 18:39:40 +00:00
Ernesto Jiménez
8de2544b9a
Fix HTTP assertions to be consistent with the rest
...
HTTP assertions were missing the trailing `msgAndArgs ...interface{}`,
making it inconsistent with the rest of the assertions and resulting in
incorrect `*f` wrappers.
Fixes #528
2017-12-30 18:45:31 +01:00
Adam Medziński
78be756ee7
Fixed HTTP assertions messages formatting and removed wrong test message
2017-05-28 13:23:04 +02:00
Adam Medziński
5c9da494dd
HTTP code status assertions now fail tests
2017-02-10 14:36:52 +01:00
Martin Hamrle
a55764f5c1
fix assertion message formatting
...
Fail and HTTPBodyNotContains expected that Fail formats messages.
2016-06-30 19:17:32 +02:00
Ernesto Jiménez
efd1b850c1
First version of code generation
2015-11-05 23:08:36 +00:00
Griffin Smith
81bd467d7c
Use "method" rather than "mode" for http tests
...
Use `method` (this is what http.NewRequest and the HTTP standard in
general calls this) rather than `mode` for `"GET"`, `"POST"`, etc.
2015-08-06 17:14:15 -04:00
Mat Ryer
e22aedd376
Tweaks and improvements - Fixes #154
2015-04-20 11:19:11 +01:00
Parker Moore
9cce94c41a
assert: fix syntax error in http assertion comments
2015-02-10 17:17:43 -08:00
Victor Kryukov
8b09ac0ee8
Implement HTTP(Success|Error|Redirect) and HTTPBody(Not)Contains
2014-09-14 11:54:12 -06:00