mirror of
https://github.com/zrepl/zrepl.git
synced 2025-08-16 09:57:49 +02:00
platformtest: harness: refactor + support SkipNow
This commit is contained in:
@ -15,6 +15,8 @@ type Context struct {
|
||||
|
||||
var FailNowSentinel = fmt.Errorf("platformtest: FailNow called on context")
|
||||
|
||||
var SkipNowSentinel = fmt.Errorf("platformtest: SkipNow called on context")
|
||||
|
||||
var _ assert.TestingT = (*Context)(nil)
|
||||
var _ require.TestingT = (*Context)(nil)
|
||||
|
||||
@ -25,3 +27,7 @@ func (c *Context) Errorf(format string, args ...interface{}) {
|
||||
func (c *Context) FailNow() {
|
||||
panic(FailNowSentinel)
|
||||
}
|
||||
|
||||
func (c *Context) SkipNow() {
|
||||
panic(SkipNowSentinel)
|
||||
}
|
||||
|
Reference in New Issue
Block a user