Skip to content

Commit 03e4d0f

Browse files
Emyrkjohnstcn
authored andcommitted
More info in the print
1 parent ab61328 commit 03e4d0f

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

coderd/authz/authztest/set_test.go

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,10 +61,13 @@ func TestRole(t *testing.T) {
6161

6262
var total uint64
6363
for _, c := range testCases {
64-
fmt.Println(c.Name)
65-
fmt.Printf("\tSize=%d\n", c.Permutations.Size)
6664
total += uint64(c.Permutations.Size)
6765
}
66+
67+
for _, c := range testCases {
68+
fmt.Printf("%s: Size=%10d, %10f%% of total\n",
69+
c.Name, c.Permutations.Size, 100*(float64(c.Permutations.Size)/float64(total)))
70+
}
6871
fmt.Printf("Total cases=%d\n", total)
6972

7073
// This is how you run the test cases

0 commit comments

Comments
 (0)