Update go dependencies
This commit is contained in:
parent
f9624cbe46
commit
307bf76454
280 changed files with 54728 additions and 2991 deletions
38
vendor/gopkg.in/gavv/httpexpect.v2/chain.go
generated
vendored
Normal file
38
vendor/gopkg.in/gavv/httpexpect.v2/chain.go
generated
vendored
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
package httpexpect
|
||||
|
||||
type chain struct {
|
||||
reporter Reporter
|
||||
failbit bool
|
||||
}
|
||||
|
||||
func makeChain(reporter Reporter) chain {
|
||||
return chain{reporter, false}
|
||||
}
|
||||
|
||||
func (c *chain) failed() bool {
|
||||
return c.failbit
|
||||
}
|
||||
|
||||
func (c *chain) fail(message string, args ...interface{}) {
|
||||
if c.failbit {
|
||||
return
|
||||
}
|
||||
c.failbit = true
|
||||
c.reporter.Errorf(message, args...)
|
||||
}
|
||||
|
||||
func (c *chain) reset() {
|
||||
c.failbit = false
|
||||
}
|
||||
|
||||
func (c *chain) assertFailed(r Reporter) {
|
||||
if !c.failbit {
|
||||
r.Errorf("expected chain is failed, but it's ok")
|
||||
}
|
||||
}
|
||||
|
||||
func (c *chain) assertOK(r Reporter) {
|
||||
if c.failbit {
|
||||
r.Errorf("expected chain is ok, but it's failed")
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue