forked from quic-go/quic-go
kill client after timeout in integration tests
this should fix the hang-issue of #163
This commit is contained in:
@@ -96,6 +96,7 @@ var _ = Describe("Integration tests", func() {
|
||||
)
|
||||
session, err := Start(command, GinkgoWriter, GinkgoWriter)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
defer session.Kill()
|
||||
Eventually(session).Should(Exit(0))
|
||||
Expect(session.Out).To(Say("Response:\nheaders: HTTP/1.1 200\nstatus: 200\n\nbody: Hello, World!\n"))
|
||||
})
|
||||
@@ -111,6 +112,7 @@ var _ = Describe("Integration tests", func() {
|
||||
)
|
||||
session, err := Start(command, GinkgoWriter, GinkgoWriter)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
defer session.Kill()
|
||||
Eventually(session).Should(Exit(0))
|
||||
Expect(session.Out).To(Say("Response:\nheaders: HTTP/1.1 200\nstatus: 200\n\nbody: foo\n"))
|
||||
})
|
||||
@@ -125,6 +127,7 @@ var _ = Describe("Integration tests", func() {
|
||||
)
|
||||
session, err := Start(command, nil, GinkgoWriter)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
defer session.Kill()
|
||||
Eventually(session, 2).Should(Exit(0))
|
||||
Expect(bytes.Contains(session.Out.Contents(), data)).To(BeTrue())
|
||||
})
|
||||
@@ -145,6 +148,7 @@ var _ = Describe("Integration tests", func() {
|
||||
)
|
||||
session, err := Start(command, nil, GinkgoWriter)
|
||||
Expect(err).NotTo(HaveOccurred())
|
||||
defer session.Kill()
|
||||
Eventually(session, 3).Should(Exit(0))
|
||||
Expect(bytes.Contains(session.Out.Contents(), data)).To(BeTrue())
|
||||
}()
|
||||
|
||||
Reference in New Issue
Block a user