summaryrefslogtreecommitdiffstats
path: root/extras/hs-test/http_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'extras/hs-test/http_test.go')
-rwxr-xr-xextras/hs-test/http_test.go25
1 files changed, 24 insertions, 1 deletions
diff --git a/extras/hs-test/http_test.go b/extras/hs-test/http_test.go
index ae1c8b82e5a..665a3e4fa86 100755
--- a/extras/hs-test/http_test.go
+++ b/extras/hs-test/http_test.go
@@ -1,5 +1,10 @@
package main
+import (
+ "os"
+ "time"
+)
+
func (s *NsSuite) TestHttpTps() {
finished := make(chan error, 1)
server_ip := "10.0.0.2"
@@ -13,7 +18,7 @@ func (s *NsSuite) TestHttpTps() {
_, err := container.execAction("ConfigureHttpTps")
s.assertNil(err)
- go startWget(finished, server_ip, port, "client")
+ go startWget(finished, server_ip, port, "test_file_10M", "client")
// wait for client
err = <-finished
s.assertNil(err)
@@ -41,3 +46,21 @@ func (s *VethsSuite) TestHttpCli() {
s.assertContains(o, "<html>", "<html> not found in the result!")
}
+
+func (s *NoTopoSuite) TestNginx() {
+ query := "return_ok"
+ finished := make(chan error, 1)
+ vppCont := s.getContainerByName("vpp")
+ vppInst := NewVppInstance(vppCont)
+ vppInst.actionFuncName = "ConfigureTap"
+ s.assertNil(vppInst.start(), "failed to start vpp")
+
+ nginxCont := s.getContainerByName("nginx")
+ s.assertNil(nginxCont.run())
+
+ time.Sleep(3 * time.Second)
+
+ defer func() { os.Remove(query) }()
+ go startWget(finished, "10.10.10.1", "80", query, "")
+ s.assertNil(<-finished)
+}