fixed error on invalid config path (#250)

This commit is contained in:
RoyUP9
2021-08-30 11:43:44 +03:00
committed by GitHub
parent a310953f05
commit 80237c8090
2 changed files with 20 additions and 6 deletions

View File

@@ -71,7 +71,6 @@ func TestTapAndFetch(t *testing.T) {
}
entries := requestResult.([]interface{})
if len(entries) == 0 {
return fmt.Errorf("unexpected entries result - Expected more than 0 entries")
}
@@ -523,6 +522,10 @@ func TestTapRedact(t *testing.T) {
}
entries := requestResult.([]interface{})
if len(entries) == 0 {
return fmt.Errorf("unexpected entries result - Expected more than 0 entries")
}
firstEntry := entries[0].(map[string]interface{})
entryUrl := fmt.Sprintf("%v/api/entries/%v", apiServerUrl, firstEntry["id"])
@@ -625,6 +628,10 @@ func TestTapNoRedact(t *testing.T) {
}
entries := requestResult.([]interface{})
if len(entries) == 0 {
return fmt.Errorf("unexpected entries result - Expected more than 0 entries")
}
firstEntry := entries[0].(map[string]interface{})
entryUrl := fmt.Sprintf("%v/api/entries/%v", apiServerUrl, firstEntry["id"])
@@ -727,6 +734,10 @@ func TestTapRegexMasking(t *testing.T) {
}
entries := requestResult.([]interface{})
if len(entries) == 0 {
return fmt.Errorf("unexpected entries result - Expected more than 0 entries")
}
firstEntry := entries[0].(map[string]interface{})
entryUrl := fmt.Sprintf("%v/api/entries/%v", apiServerUrl, firstEntry["id"])