From ddadc9a0bba122562637a949dc52c7f0e8c443a9 Mon Sep 17 00:00:00 2001 From: Antonio Ojea Date: Sat, 26 Mar 2022 09:19:55 +0100 Subject: [PATCH] reorganize controlplane integration tests --- .../controlplane/{ => audit}/audit_test.go | 2 +- .../controlplane/audit/main_test.go | 27 +++++++++++++++++++ .../kms_transformation_test.go | 2 +- .../controlplane/transformation/main_test.go | 27 +++++++++++++++++++ .../secrets_transformation_test.go | 2 +- .../transformation_testcase.go | 2 +- 6 files changed, 58 insertions(+), 4 deletions(-) rename test/integration/controlplane/{ => audit}/audit_test.go (99%) create mode 100644 test/integration/controlplane/audit/main_test.go rename test/integration/controlplane/{ => transformation}/kms_transformation_test.go (99%) create mode 100644 test/integration/controlplane/transformation/main_test.go rename test/integration/controlplane/{ => transformation}/secrets_transformation_test.go (99%) rename test/integration/controlplane/{ => transformation}/transformation_testcase.go (99%) diff --git a/test/integration/controlplane/audit_test.go b/test/integration/controlplane/audit/audit_test.go similarity index 99% rename from test/integration/controlplane/audit_test.go rename to test/integration/controlplane/audit/audit_test.go index 1527f332ab6..6bda88ed0aa 100644 --- a/test/integration/controlplane/audit_test.go +++ b/test/integration/controlplane/audit/audit_test.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package controlplane +package audit import ( "context" diff --git a/test/integration/controlplane/audit/main_test.go b/test/integration/controlplane/audit/main_test.go new file mode 100644 index 00000000000..92bea609f38 --- /dev/null +++ b/test/integration/controlplane/audit/main_test.go @@ -0,0 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. + +Licensed 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 audit + +import ( + "testing" + + "k8s.io/kubernetes/test/integration/framework" +) + +func TestMain(m *testing.M) { + framework.EtcdMain(m.Run) +} diff --git a/test/integration/controlplane/kms_transformation_test.go b/test/integration/controlplane/transformation/kms_transformation_test.go similarity index 99% rename from test/integration/controlplane/kms_transformation_test.go rename to test/integration/controlplane/transformation/kms_transformation_test.go index 6640f695093..08f0f0a3da8 100644 --- a/test/integration/controlplane/kms_transformation_test.go +++ b/test/integration/controlplane/transformation/kms_transformation_test.go @@ -17,7 +17,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package controlplane +package transformation import ( "bytes" diff --git a/test/integration/controlplane/transformation/main_test.go b/test/integration/controlplane/transformation/main_test.go new file mode 100644 index 00000000000..575b438c50c --- /dev/null +++ b/test/integration/controlplane/transformation/main_test.go @@ -0,0 +1,27 @@ +/* +Copyright 2022 The Kubernetes Authors. + +Licensed 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 transformation + +import ( + "testing" + + "k8s.io/kubernetes/test/integration/framework" +) + +func TestMain(m *testing.M) { + framework.EtcdMain(m.Run) +} diff --git a/test/integration/controlplane/secrets_transformation_test.go b/test/integration/controlplane/transformation/secrets_transformation_test.go similarity index 99% rename from test/integration/controlplane/secrets_transformation_test.go rename to test/integration/controlplane/transformation/secrets_transformation_test.go index 6c0090dbab2..b899237a937 100644 --- a/test/integration/controlplane/secrets_transformation_test.go +++ b/test/integration/controlplane/transformation/secrets_transformation_test.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package controlplane +package transformation import ( "context" diff --git a/test/integration/controlplane/transformation_testcase.go b/test/integration/controlplane/transformation/transformation_testcase.go similarity index 99% rename from test/integration/controlplane/transformation_testcase.go rename to test/integration/controlplane/transformation/transformation_testcase.go index 82e8d8b0bc0..48af30bba43 100644 --- a/test/integration/controlplane/transformation_testcase.go +++ b/test/integration/controlplane/transformation/transformation_testcase.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package controlplane +package transformation import ( "bytes"