260d6905a4
This command runs through the cluster and reports expirable entities Reference:- https://hackmd.io/aGaz7YXSSHybGcyol8vYEw Previous work:- https://review.opendev.org/#/c/755291/ Below is the complete ordered flow of PS for the feature: https://review.opendev.org/#/c/760498/ - Cobra command https://review.opendev.org/#/c/760501/ - Command Objects https://review.opendev.org/#/c/760504/ - TLS check https://review.opendev.org/#/c/760517/ - Kubeconf check https://review.opendev.org/#/c/760532/ - Node check https://review.opendev.org/#/c/760537/ - Combined Unit tests Change-Id: I7e20a6d3821877e16a5bc2cb8de3dd3c8b7850e2 Relates-To: #391
37 lines
964 B
Go
37 lines
964 B
Go
/*
|
|
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
|
|
|
|
https://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 checkexpiration_test
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"opendev.org/airship/airshipctl/cmd/cluster/checkexpiration"
|
|
"opendev.org/airship/airshipctl/testutil"
|
|
)
|
|
|
|
func TestCheckExpiration(t *testing.T) {
|
|
cmdTests := []*testutil.CmdTest{
|
|
{
|
|
Name: "check-expiration-with-help",
|
|
CmdLine: "--help",
|
|
Cmd: checkexpiration.NewCheckCommand(nil),
|
|
},
|
|
}
|
|
|
|
for _, tt := range cmdTests {
|
|
testutil.RunTest(t, tt)
|
|
}
|
|
}
|