Skip to content

Commit

Permalink
Fix ingester related test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
nitisht committed Oct 26, 2023
1 parent ac65b60 commit 9683042
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion model.go
Original file line number Diff line number Diff line change
Expand Up @@ -369,5 +369,5 @@ func RoleReader(stream string) string {
}

func RoleIngester(stream string) string {
return fmt.Sprintf(`[{"privilege": "ingest", "resource": {"stream": "%s"}}]`, stream)
return fmt.Sprintf(`[{"privilege": "ingester", "resource": {"stream": "%s"}}]`, stream)
}
2 changes: 1 addition & 1 deletion quest_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ func TestSmokeRoles(t *testing.T) {
body: RoleWriter(NewGlob.Stream),
},
{
roleName: "ingest",
roleName: "ingester",
body: RoleIngester(NewGlob.Stream),
},
}
Expand Down
2 changes: 1 addition & 1 deletion test_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ func checkAPIAccess(t *testing.T, client HTTPClient, stream string, role string)
require.NoErrorf(t, err, "Request failed: %s", err)
require.Equalf(t, 403, response.StatusCode, "Server returned http code: %s and response: %s", response.Status, readAsString(response.Body))

case "ingest":
case "ingester":
// Check access to non-protected API
req, _ := client.NewRequest("GET", "liveness", nil)
response, err := client.Do(req)
Expand Down

0 comments on commit 9683042

Please sign in to comment.