package
0.0.0-20210831081626-d823fe11ceba
Repository: https://github.com/huaweicloud/golangsdk.git
Documentation: pkg.go.dev
# Functions
AssertByteArrayEquals a convenience function for checking whether two byte arrays are equal.
AssertDeepEquals - like Equals - performs a comparison - but on more complex structures that requires deeper inspection.
AssertEquals compares two arbitrary values and performs a comparison.
AssertJSONEquals serializes a value as JSON, parses an expected string as JSON, and ensures that both are consistent.
AssertNoErr is a convenience function for checking whether an error value is an actual error.
CheckByteArrayEquals a convenience function for silent checking whether two byte arrays are equal.
CheckDeepEquals is similar to AssertDeepEquals, except with a non-fatal error.
CheckEquals is similar to AssertEquals, except with a non-fatal error.
CheckJSONEquals is similar to AssertJSONEquals, but nonfatal.
CheckNoErr is similar to AssertNoErr, except with a non-fatal error.
Endpoint returns a fake endpoint that will actually target the Mux.
SetupHTTP prepares the Mux and Server.
TeardownHTTP releases HTTP-related resources.
TestBody verifies that the request body matches an expected body.
TestFormValues ensures that all the URL parameters given to the http.Request are the same as values.
TestHeader checks that the header on the http.Request matches the expected value.
TestJSONRequest verifies that the JSON payload of a request matches an expected structure, without asserting things about whitespace or ordering.
TestMethod checks that the Request has the expected method (e.g.