From 98a573b1866ab8db2f4810d7b7ee4a709f278d31 Mon Sep 17 00:00:00 2001 From: lhy1024 Date: Thu, 14 Sep 2023 11:39:07 +0800 Subject: [PATCH] address comments Signed-off-by: lhy1024 --- server/api/server.go | 2 ++ tests/pdctl/operator/operator_test.go | 2 +- tests/pdctl/scheduler/scheduler_test.go | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/server/api/server.go b/server/api/server.go index fa7d174cac8..0094d8eb5dd 100644 --- a/server/api/server.go +++ b/server/api/server.go @@ -64,6 +64,8 @@ func NewHandler(_ context.Context, svr *server.Server) (http.Handler, apiutil.AP scheapi.APIPathPrefix+"/schedulers", mcs.SchedulingServiceName, []string{http.MethodGet}), + // TODO: we need to consider the case that v1 api not support restful api. + // we might change the previous path parameters to query parameters. ), negroni.Wrap(r)), ) diff --git a/tests/pdctl/operator/operator_test.go b/tests/pdctl/operator/operator_test.go index 63d62c8a874..b1acfcfefe6 100644 --- a/tests/pdctl/operator/operator_test.go +++ b/tests/pdctl/operator/operator_test.go @@ -253,7 +253,7 @@ func TestOperator(t *testing.T) { }) } -func TestMicroservice(t *testing.T) { +func TestOperatorInMicroservice(t *testing.T) { re := require.New(t) ctx, cancel := context.WithCancel(context.Background()) defer cancel() diff --git a/tests/pdctl/scheduler/scheduler_test.go b/tests/pdctl/scheduler/scheduler_test.go index b13790991c4..c5815c35dd2 100644 --- a/tests/pdctl/scheduler/scheduler_test.go +++ b/tests/pdctl/scheduler/scheduler_test.go @@ -531,7 +531,7 @@ func mightExec(re *require.Assertions, cmd *cobra.Command, args []string, v inte json.Unmarshal(output, v) } -func TestMicroservice(t *testing.T) { +func TestSchedulerInMicroservice(t *testing.T) { re := require.New(t) ctx, cancel := context.WithCancel(context.Background()) defer cancel()