e2e test cleanup

- fix a typo that was resulting in a test being a NOP, and
   add actual testing to it.

 - fix two Expects() with incorrectly-ordered actual/expects

 - remove leading whitespace from an It() test name

 - To(BeTrue()) is evil. Wherever possible, replace it with
   useful string or field checks. When not possible, use
   the annotation field to indicate what failed. I got
   carried away here, #sorrynotsorry

 - remove unused system-test code

Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
Ed Santiago
2023-04-18 06:11:56 -06:00
parent f173db755d
commit 3050a64373
27 changed files with 64 additions and 93 deletions

View File

@ -119,15 +119,8 @@ var _ = Describe("Podman commit", func() {
check := podmanTest.Podman([]string{"inspect", "foobar.com/test1-image:latest"})
check.WaitWithDefaultTimeout()
data := check.InspectImageJSON()
foundBlue := false
for _, i := range data[0].Labels {
if i == "blue" {
foundBlue = true
break
}
}
Expect(foundBlue).To(BeTrue())
inspectResults := check.InspectImageJSON()
Expect(inspectResults[0].Labels).To(HaveKeyWithValue("image", "blue"))
})
It("podman commit container with --squash", func() {