add new methods to authorization_test
@@ -48,6 +48,12 @@ func Test_Schema_Authorization(t *testing.T) {
expectedVerb: "list",
expectedResource: "schema/*",
},
+ testCase{
+ methodName: "GetShardsStatus",
+ additionalArgs: []interface{}{"className"},
+ expectedVerb: "list",
+ expectedResource: "schema/className/shards",
+ },
testCase{
methodName: "AddClass",
additionalArgs: []interface{}{&models.Class{}},
@@ -84,6 +90,12 @@ func Test_Schema_Authorization(t *testing.T) {
expectedVerb: "update",
expectedResource: "schema/objects",
},
+ testCase{
+ methodName: "UpdateShardStatus",
+ additionalArgs: []interface{}{"className", "shardName", "targetStatus"},
+ expectedVerb: "update",
+ expectedResource: "schema/className/shards/shardName",
+ },
}
t.Run("verify that a test for every public method exists", func(t *testing.T) {
