Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Fix benchmark to match objects
  • Loading branch information
Emyrk committed Feb 9, 2023
commit 842009433024d4292c7ed7968b3710ae69f7b044
6 changes: 5 additions & 1 deletion coderd/rbac/builtin_internal_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,11 @@ func BenchmarkRBACValueAllocation(b *testing.B) {
})
b.Run("JSONRegoValue", func(b *testing.B) {
for i := 0; i < b.N; i++ {
_, err := ast.InterfaceToValue(jsonSubject)
_, err := ast.InterfaceToValue(map[string]interface{}{
"subject": jsonSubject,
"action": ActionRead,
"object": obj,
})
require.NoError(b, err)
}
})
Expand Down
Empty file added coderd/rbac/testinput.json
Empty file.