func checkEvenPositive(is *testy.T, n int) { // replace 'is' with a labeled, upleveled equivalent is = is.Uplevel(1).Label("Testing", n) if n < 1 { is.Error("was not positive") } if n%2 != 0 { is.Error("was not even") } }
func checkTrue(is *testy.T, cond bool) { if !cond { is.Uplevel(1).Error("Expression was not true") } }
func checkEven(is *testy.T, n int) { is = is.Uplevel(1).Label("Testing", n) if n%2 != 0 { is.Error("Value is not even") } }