fixing bmp expected results in beryllium 59/46459/2
authorPeter Gubka <pgubka@cisco.com>
Tue, 4 Oct 2016 10:43:59 +0000 (12:43 +0200)
committerVratko Polák <vrpolak@cisco.com>
Tue, 4 Oct 2016 15:43:29 +0000 (15:43 +0000)
Change-Id: I32bd1d06be53b22a575ac581ebff499ec186012b
Signed-off-by: Peter Gubka <pgubka@cisco.com>
csit/suites/bgpcep/bgpfunct/050_bmp_basic.robot
csit/variables/bgpfunctional/bmp_basic_Be/data.json [new file with mode: 0644]
csit/variables/bgpfunctional/bmp_basic_Be/location.uri [new file with mode: 0644]

index fb05935a89be2b637091cbb743368cc59407f35e..ee747484867a8037334c951d9034d06030e77b29 100644 (file)
@@ -43,7 +43,8 @@ Start_Bmp_Mock
 Verify Data Reported
     [Documentation]    Verifies if the tool reported expected data
     &{mapping}    BuiltIn.Create_Dictionary    TOOL_IP=${TOOLS_SYSTEM_IP}
-    BuiltIn.Wait_Until_Keyword_Succeeds    3x    2s    TemplatedRequests.Get_As_Json_Templated    folder=${BGP_BMP_DIR}    mapping=${mapping}    session=${CONFIG_SESSION}
+    ${bmp_dir}=    CompareStream.Set_Variable_If_At_Least_Boron    ${BGP_BMP_DIR}    ${BGP_BMP_DIR}_Be
+    BuiltIn.Wait_Until_Keyword_Succeeds    3x    2s    TemplatedRequests.Get_As_Json_Templated    folder=${bmp_dir}    mapping=${mapping}    session=${CONFIG_SESSION}
     ...    verify=True
 
 Stop_Bmp_Mock
diff --git a/csit/variables/bgpfunctional/bmp_basic_Be/data.json b/csit/variables/bgpfunctional/bmp_basic_Be/data.json
new file mode 100644 (file)
index 0000000..58bc592
--- /dev/null
@@ -0,0 +1,58 @@
+{
+    "bmp-monitor": {
+        "monitor": [
+            {
+                "monitor-id": "example-bmp-monitor",
+                "router": [
+                    {
+                        "router-id": "$TOOL_IP",
+                        "peer": [
+                            {
+                                "peer-id": "1.1.1.1",
+                                "as": 65431,
+                                "address": "1.1.1.1",
+                                "bgp-id": "1.1.1.1",
+                                "pre-policy-rib": {
+                                    "tables": [
+                                        {
+                                            "afi": "bgp-types:ipv4-address-family",
+                                            "safi": "bgp-types:unicast-subsequent-address-family",
+                                            "bgp-inet:ipv4-routes": {},
+                                            "attributes": {
+                                                "uptodate": false
+                                            }
+                                        }
+                                    ]
+                                },
+                                "peer-session": {
+                                    "remote-port": 179,
+                                    "status": "up",
+                                    "local-address": "$TOOL_IP",
+                                    "timestamp-sec": 0,
+                                    "local-port": 179
+                                },
+                                "post-policy-rib": {
+                                    "tables": [
+                                        {
+                                            "afi": "bgp-types:ipv4-address-family",
+                                            "safi": "bgp-types:unicast-subsequent-address-family",
+                                            "bgp-inet:ipv4-routes": {},
+                                            "attributes": {
+                                                "uptodate": false
+                                            }
+                                        }
+                                    ]
+                                },
+                                "type": "global"
+                            }
+                        ],
+                        "status": "up",
+                        "info": "",
+                        "description": "OpenDaylight",
+                        "name": "BMP mock"
+                    }
+                ]
+            }
+        ]
+    }
+}
diff --git a/csit/variables/bgpfunctional/bmp_basic_Be/location.uri b/csit/variables/bgpfunctional/bmp_basic_Be/location.uri
new file mode 100644 (file)
index 0000000..513abc0
--- /dev/null
@@ -0,0 +1 @@
+/restconf/operational/bmp-monitor:bmp-monitor