mirror of
https://github.com/TwiN/gatus.git
synced 2024-11-22 07:53:38 +01:00
Add TestEvalWithInvalidData
This commit is contained in:
parent
8106832d69
commit
e3038f0e80
@ -20,6 +20,15 @@ func TestEval(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
func TestEvalWithInvalidData(t *testing.T) {
|
||||
path := "simple"
|
||||
data := `invalid data`
|
||||
_, _, err := Eval(path, []byte(data))
|
||||
if err == nil {
|
||||
t.Error("expected an error")
|
||||
}
|
||||
}
|
||||
|
||||
func TestEvalWithInvalidPath(t *testing.T) {
|
||||
path := "errors"
|
||||
data := `{}`
|
||||
|
Loading…
Reference in New Issue
Block a user