-
Notifications
You must be signed in to change notification settings - Fork 39
/
Copy pathmain_test.go
21 lines (18 loc) · 908 Bytes
/
main_test.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package main_test
import (
"os/exec"
. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
)
var _ = Describe("control-tower", func() {
It("displays usage instructions on --help", func() {
output, err := exec.Command("go", "run", "github.com/EngineerBetter/control-tower", "--help").CombinedOutput()
Expect(err).NotTo(HaveOccurred())
outputStr := string(output)
Expect(outputStr).To(ContainSubstring("Control-Tower - A CLI tool to deploy Concourse CI"), outputStr)
Expect(outputStr).To(ContainSubstring("deploy, d Deploys or updates a Concourse"), outputStr)
Expect(outputStr).To(ContainSubstring("destroy, x Destroys a Concourse"), outputStr)
Expect(outputStr).To(ContainSubstring("info, i Fetches information on a deployed environment"), outputStr)
Expect(outputStr).To(ContainSubstring("maintain, m Handles maintenance operations in control-tower"), outputStr)
})
})