mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 10:33:35 +00:00
rebase: bump github.com/onsi/gomega from 1.13.0 to 1.16.0
Bumps [github.com/onsi/gomega](https://github.com/onsi/gomega) from 1.13.0 to 1.16.0. - [Release notes](https://github.com/onsi/gomega/releases) - [Changelog](https://github.com/onsi/gomega/blob/master/CHANGELOG.md) - [Commits](https://github.com/onsi/gomega/compare/v1.13.0...v1.16.0) --- updated-dependencies: - dependency-name: github.com/onsi/gomega dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
96ba1d4799
commit
e8efa272a6
21
vendor/github.com/onsi/gomega/matchers.go
generated
vendored
21
vendor/github.com/onsi/gomega/matchers.go
generated
vendored
@ -423,10 +423,29 @@ func BeADirectory() types.GomegaMatcher {
|
||||
//Expected must be either an int or a string.
|
||||
// Expect(resp).Should(HaveHTTPStatus(http.StatusOK)) // asserts that resp.StatusCode == 200
|
||||
// Expect(resp).Should(HaveHTTPStatus("404 Not Found")) // asserts that resp.Status == "404 Not Found"
|
||||
func HaveHTTPStatus(expected interface{}) types.GomegaMatcher {
|
||||
// Expect(resp).Should(HaveHTTPStatus(http.StatusOK, http.StatusNoContent)) // asserts that resp.StatusCode == 200 || resp.StatusCode == 204
|
||||
func HaveHTTPStatus(expected ...interface{}) types.GomegaMatcher {
|
||||
return &matchers.HaveHTTPStatusMatcher{Expected: expected}
|
||||
}
|
||||
|
||||
// HaveHTTPHeaderWithValue succeeds if the header is found and the value matches.
|
||||
// Actual must be either a *http.Response or *httptest.ResponseRecorder.
|
||||
// Expected must be a string header name, followed by a header value which
|
||||
// can be a string, or another matcher.
|
||||
func HaveHTTPHeaderWithValue(header string, value interface{}) types.GomegaMatcher {
|
||||
return &matchers.HaveHTTPHeaderWithValueMatcher{
|
||||
Header: header,
|
||||
Value: value,
|
||||
}
|
||||
}
|
||||
|
||||
// HaveHTTPBody matches if the body matches.
|
||||
// Actual must be either a *http.Response or *httptest.ResponseRecorder.
|
||||
// Expected must be either a string, []byte, or other matcher
|
||||
func HaveHTTPBody(expected interface{}) types.GomegaMatcher {
|
||||
return &matchers.HaveHTTPBodyMatcher{Expected: expected}
|
||||
}
|
||||
|
||||
//And succeeds only if all of the given matchers succeed.
|
||||
//The matchers are tried in order, and will fail-fast if one doesn't succeed.
|
||||
// Expect("hi").To(And(HaveLen(2), Equal("hi"))
|
||||
|
Reference in New Issue
Block a user