Multiple changes to the test framework. Interim commit
to avoid losing code if my VM crashes
Change-Id: I5f03db81851dba1fb0c944c8e5f3a845ddbec2c8
diff --git a/tests/afrouter/tester.go b/tests/afrouter/tester.go
index e3d883c..939cc24 100644
--- a/tests/afrouter/tester.go
+++ b/tests/afrouter/tester.go
@@ -74,6 +74,8 @@
Method string `json:"method"`
Param string `json:"param"`
Expect string `json:"expect"`
+ MetaData []MetaD `json:"meta"`
+ ExpectMeta []MetaD `json:"expectMeta"`
}
type MetaD struct {
@@ -110,6 +112,8 @@
ParamType string
Expect string
ExpectType string
+ MetaData []MetaD
+ ExpectMeta []MetaD
}
type TestCase struct {
@@ -429,6 +433,12 @@
test.Send.ParamType = mthdMap[test.Send.Method].Param
test.Send.Expect = v.Send.Expect
test.Send.ExpectType = mthdMap[test.Send.Method].Rtrn
+ for _,v1 := range v.Send.MetaData {
+ test.Send.MetaData = append(test.Send.MetaData,v1)
+ }
+ for _,v1 := range v.Send.ExpectMeta {
+ test.Send.ExpectMeta = append(test.Send.ExpectMeta,v1)
+ }
for _,v1 := range v.Servers {
var srvr Server
if serverExists(v1.Name, ts) == false {