This is an automated email from the ASF dual-hosted git repository. justxuewei pushed a commit to branch revert-552-integration_test_0402 in repository https://gitbox.apache.org/repos/asf/dubbo-go-samples.git
commit 286787702b86545d7cf672543db604193bc94d33 Author: Xuewei Niu <[email protected]> AuthorDate: Wed Apr 5 16:26:52 2023 +0800 Revert "feat: token filter & config merge integrate test (#552)" This reverts commit 66e369fc7adbf798dd1360f3946a168b62be4f96. --- .../config-merge/tests/integration/main_test.go | 41 ---------------------- .../config-merge/tests/integration/merge_test.go | 41 ---------------------- .../filter/token/tests/integration/main_test.go | 41 ---------------------- .../filter/token/tests/integration/token_test.go | 41 ---------------------- start_integrate_test.sh | 2 -- 5 files changed, 166 deletions(-) diff --git a/integrate_test/config-api/config-merge/tests/integration/main_test.go b/integrate_test/config-api/config-merge/tests/integration/main_test.go deleted file mode 100644 index fb272bf4..00000000 --- a/integrate_test/config-api/config-merge/tests/integration/main_test.go +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package integration - -import ( - "testing" -) - -import ( - "dubbo.apache.org/dubbo-go/v3/config" - _ "dubbo.apache.org/dubbo-go/v3/imports" -) - -import ( - "github.com/apache/dubbo-go-samples/api" -) - -var userProvider = &api.GreeterClientImpl{} - -func TestMain(m *testing.M) { - config.SetConsumerService(userProvider) - err := config.Load() - if err != nil { - panic(err) - } -} diff --git a/integrate_test/config-api/config-merge/tests/integration/merge_test.go b/integrate_test/config-api/config-merge/tests/integration/merge_test.go deleted file mode 100644 index 505c21b1..00000000 --- a/integrate_test/config-api/config-merge/tests/integration/merge_test.go +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package integration - -import ( - "context" - "testing" -) - -import ( - "github.com/stretchr/testify/assert" -) - -import ( - "github.com/apache/dubbo-go-samples/api" -) - -func TestToken(t *testing.T) { - user, err := userProvider.SayHello(context.TODO(), &api.HelloRequest{Name: "dubbo-go"}) - - assert.Nil(t, err) - assert.Equal(t, "Hello dubbo-go", user.Name) - assert.Equal(t, "12345", user.Id) - assert.Equal(t, 21, user.Age) - -} diff --git a/integrate_test/filter/token/tests/integration/main_test.go b/integrate_test/filter/token/tests/integration/main_test.go deleted file mode 100644 index fb272bf4..00000000 --- a/integrate_test/filter/token/tests/integration/main_test.go +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package integration - -import ( - "testing" -) - -import ( - "dubbo.apache.org/dubbo-go/v3/config" - _ "dubbo.apache.org/dubbo-go/v3/imports" -) - -import ( - "github.com/apache/dubbo-go-samples/api" -) - -var userProvider = &api.GreeterClientImpl{} - -func TestMain(m *testing.M) { - config.SetConsumerService(userProvider) - err := config.Load() - if err != nil { - panic(err) - } -} diff --git a/integrate_test/filter/token/tests/integration/token_test.go b/integrate_test/filter/token/tests/integration/token_test.go deleted file mode 100644 index 505c21b1..00000000 --- a/integrate_test/filter/token/tests/integration/token_test.go +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package integration - -import ( - "context" - "testing" -) - -import ( - "github.com/stretchr/testify/assert" -) - -import ( - "github.com/apache/dubbo-go-samples/api" -) - -func TestToken(t *testing.T) { - user, err := userProvider.SayHello(context.TODO(), &api.HelloRequest{Name: "dubbo-go"}) - - assert.Nil(t, err) - assert.Equal(t, "Hello dubbo-go", user.Name) - assert.Equal(t, "12345", user.Id) - assert.Equal(t, 21, user.Age) - -} diff --git a/start_integrate_test.sh b/start_integrate_test.sh index 9b825e27..26dd2bef 100755 --- a/start_integrate_test.sh +++ b/start_integrate_test.sh @@ -23,7 +23,6 @@ array+=("game/go-server-gate") array=("config-api/rpc/triple") array+=("config-api/configcenter/nacos") array+=("config-api/configcenter/zookeeper") -array=("config-api/config-merge") # error array+=("error/triple/hessian2") @@ -40,7 +39,6 @@ array+=("direct") # filer array+=("filter/custom") -array+=("filter/token") # context array+=("context/dubbo")
