airshipctl/cmd/phase/list_test.go
Niharika Bhavaraju 0cc7c9cafd [#358] Introduce Phase List command to output phase list(cmd module)
* Phase list command lists phases of current documentset/plan.
 airshipctl phase list
 airshipctl phase list --plan planName
 airshipctl phase list --plan planName -o table(default output)
 airshipctl phase list --plan planName -o yaml

Co-Authored-By: Niharika Bhavaraju <niha.twinkle@gmail.com>

Relates-To: #358

Change-Id: Iab3a6cdf5a25583ba3d01341da350841c9cc362d
2021-03-25 16:11:10 +00:00

36 lines
927 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 phase_test
import (
"testing"
"opendev.org/airship/airshipctl/cmd/phase"
"opendev.org/airship/airshipctl/testutil"
)
func TestNewListCommand(t *testing.T) {
tests := []*testutil.CmdTest{
{
Name: "phase-list-cmd-with-help",
CmdLine: "--help",
Cmd: phase.NewListCommand(nil),
},
}
for _, testcase := range tests {
testutil.RunTest(t, testcase)
}
}