Skip to content

Commit

Permalink
feat: verify the result of finch inspect has State.Status and State.E…
Browse files Browse the repository at this point in the history
…rror (#64)

verify the result of finch inspect has State.Status and State.Error

runfinch/finch#242

*Description of changes:*
Test for the scenario of the issue

*Testing done:*
Tested locally.


- [ X ] I've reviewed the guidance in CONTRIBUTING.md


#### License Acceptance

By submitting this pull request, I confirm that my contribution is made
under the terms of the Apache 2.0 license.

Signed-off-by: Ziwen Ning <[email protected]>
  • Loading branch information
ningziwen authored May 19, 2023
1 parent 72120b5 commit b761a7a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ func Inspect(o *option.Option) {
gomega.Expect(image).To(gomega.Equal(defaultImage))
containerName := command.StdoutStr(o, "inspect", "--format", "{{.Name}}", testContainerName)
gomega.Expect(containerName).To(gomega.Equal(testContainerName))
gomega.Expect(command.StdoutStr(o, "inspect", "--format", "{{.State.Status}}", testContainerName)).To(gomega.Equal("exited"))
gomega.Expect(command.StdoutStr(o, "inspect", "--format", "{{.State.Error}}", testContainerName)).To(gomega.Equal(""))
})

ginkgo.It("should display multiple container image with --format flag", func() {
Expand Down

0 comments on commit b761a7a

Please sign in to comment.