mirror of
https://github.com/containers/podman.git
synced 2025-11-29 17:48:05 +08:00
Oops! Manual edits to broken tests
Commit 2 of 2: there were (still are?) a bunch of string
checks that didn't have a corresponding Expect(). IIUC
that means they were NOPs. Try to identify and fix those.
The first few were caught by Go linting, "ok is defined
but not used". When I realized the problem, I looked for
more using:
$ ack -A2 LineInOutputStartsWith
...and tediously eyeballing the results, looking for
matches in which the next line was not Expect(). If
test was wrong (e.g. "server" should've been "nameserver"),
fix that.
Also: remove the remove-betrue script. We don't need it
in the repo, I just wanted to preserve it for posterity.
Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
@@ -224,21 +224,21 @@ var _ = Describe("Podman run", func() {
|
||||
session := podmanTest.Podman([]string{"run", ALPINE, "cat", "/etc/resolv.conf"})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
session.LineInOutputStartsWith("search foobar.com")
|
||||
Expect(session.OutputToStringArray()).To(ContainElement(HavePrefix("search foobar.com")))
|
||||
})
|
||||
|
||||
It("podman run add dns server", func() {
|
||||
session := podmanTest.Podman([]string{"run", ALPINE, "cat", "/etc/resolv.conf"})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
session.LineInOutputStartsWith("server 1.2.3.4")
|
||||
Expect(session.OutputToStringArray()).To(ContainElement(HavePrefix("nameserver 1.2.3.4")))
|
||||
})
|
||||
|
||||
It("podman run add dns option", func() {
|
||||
session := podmanTest.Podman([]string{"run", ALPINE, "cat", "/etc/resolv.conf"})
|
||||
session.WaitWithDefaultTimeout()
|
||||
Expect(session).Should(Exit(0))
|
||||
session.LineInOutputStartsWith("options debug")
|
||||
Expect(session.OutputToStringArray()).To(ContainElement(HavePrefix("options debug")))
|
||||
})
|
||||
|
||||
It("podman run containers.conf remove all search domain", func() {
|
||||
|
||||
Reference in New Issue
Block a user