[VOL-4097] Verify that best effort BW is released to assured BW requirement as needed and that fixed BW is reserved always on the PON

Change-Id: Ib1edef53aeaf9c015afc0e8fca1f6500706ca086
diff --git a/tests/data/flex-ocp-cord-TT-multi-tcont-tests-input.yaml b/tests/data/flex-ocp-cord-TT-multi-tcont-tests-input.yaml
index 08aa74d..e99c6b2 100644
--- a/tests/data/flex-ocp-cord-TT-multi-tcont-tests-input.yaml
+++ b/tests/data/flex-ocp-cord-TT-multi-tcont-tests-input.yaml
@@ -53,7 +53,7 @@
     -
       onu: 'ALPHe3d1cea3'
       service_type: 'hsia'
-      us_bw_profile: 'TCONT_TYPE4_1Gbps_Peak_User1_HSI_Upstream'
+      us_bw_profile: 'TCONT_TYPE4_300Mbps_Peak_User1_HSI_Upstream'
     -
       onu: 'ALPHe3d1ceb7'
       service_type: 'hsia'
diff --git a/tests/data/flex-ocp-cord-sadis-TT-multi-tcont-1.json b/tests/data/flex-ocp-cord-sadis-TT-multi-tcont-1.json
new file mode 100644
index 0000000..faa38f8
--- /dev/null
+++ b/tests/data/flex-ocp-cord-sadis-TT-multi-tcont-1.json
@@ -0,0 +1,294 @@
+{
+  "ports" : { },
+  "devices" : { },
+  "hosts" : { },
+  "apps" : {
+    "org.onosproject.provider.lldp" : {
+      "suppression" : {
+        "deviceTypes" : [ "ROADM", "OTN", "FIBER_SWITCH", "OPTICAL_AMPLIFIER" ],
+        "annotation" : "{\"no-lldp\":null}"
+      }
+    },
+    "org.opencord.kafka" : { },
+    "org.onosproject.core" : {
+      "multicast" : {
+        "ingressVlan" : 550,
+        "egressVlan" : 550,
+        "egressInnerVlan" : 55
+      }
+    },
+    "org.opencord.sadis" : {
+      "bandwidthprofile" : {
+        "integration" : {
+          "cache" : {
+            "enabled" : true,
+            "maxsize" : 40,
+            "ttl" : "PT1m"
+          }
+        },
+        "entries" : [ {
+          "id" : "High-Speed-Internet",
+          "cir" : 100000,
+          "cbs" : 10000,
+          "eir" : 100000,
+          "ebs" : 10000,
+          "air" : 100000
+        }, {
+          "id" : "VOIP",
+          "cir" : 400000,
+          "cbs" : 10000,
+          "eir" : 400000,
+          "ebs" : 10000,
+          "air" : 100000
+        }, {
+          "id" : "User1-Specific",
+          "cir" : 60000,
+          "cbs" : 10000,
+          "eir" : 40000,
+          "ebs" : 10000
+        }, {
+          "id" : "User1-Specific2",
+          "cir" : 500000,
+          "cbs" : 10000,
+          "eir" : 300000,
+          "ebs" : 10000
+        },{
+          "id" : "TCONT_TYPE1_Fixed8.7Gbps",
+          "cir" : 0,
+          "cbs" : 0,
+          "eir" : 0,
+          "ebs" : 0,
+          "air" : 8700000
+        }, {
+          "id" : "TCONT_TYPE1_200Mbps_Fixed_ForVOIP",
+          "eir" : 0,
+          "ebs" : 0,
+          "cir" : 0,
+          "cbs" : 0,
+          "air" : 200000
+        }, {
+          "id" : "TCONT_TYPE1_1Mbps_Fixed",
+          "eir" : 0,
+          "ebs" : 0,
+          "cir" : 0,
+          "cbs" : 0,
+          "air" : 1000
+        }, {
+          "id" : "TCONT_TYPE2_500Mbps_Assured_ForVoD",
+          "eir" : 0,
+          "ebs" : 0,
+          "cir" : 500000,
+          "cbs" : 10000,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE3_700Mbps_Peak_500Mbps_Assured_ForVoD",
+          "eir" : 200000,
+          "ebs" : 10000,
+          "cir" : 500000,
+          "cbs" : 10000,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE3_2Mbps_Peak_1Mbps_Assured_ForVoD",
+          "eir" : 1000,
+          "ebs" : 10000,
+          "cir" : 1000,
+          "cbs" : 10000,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE3_1G_Peak_500Mbps_Assured_ForVoD",
+          "eir" : 500000,
+          "ebs" : 10000,
+          "cir" : 500000,
+          "cbs" : 10000,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE4_1Gbps_Peak_User1_HSI_Upstream",
+          "eir" : 1000000,
+          "ebs" : 10000,
+          "cir" : 0,
+          "cbs" : 0,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE4_300Mbps_Peak_User1_HSI_Upstream",
+          "eir" : 300000,
+          "ebs" : 10000,
+          "cir" : 0,
+          "cbs" : 0,
+          "air" : 0
+        }, {
+          "id" : "TCONT_TYPE5_1Gbps_Peak_500Mbps_Assured_200Mbps_Fixed_User1_HSI_Upstream",
+          "eir" : 300000,
+          "ebs" : 10000,
+          "cir" : 500000,
+          "cbs" : 10000,
+          "air" : 200000
+        } ]
+      },
+      "sadis" : {
+        "integration" : {
+          "cache" : {
+            "enabled" : true,
+            "maxsize" : 50,
+            "ttl" : "PT1m"
+          }
+        },
+        "entries" : [ {
+          "id" : "ALPHe3d1cfa7-1",
+          "nasPortId" : "ALPHe3d1cfa7-1",
+          "circuitId" : "ALPHe3d1cfa7-1",
+          "remoteId" : "ALPHe3d1cfa7-1",
+          "uniTagList" : [ {
+            "uniTagMatch" : 65,
+            "ponCTag" : 444,
+            "ponSTag" : 333,
+            "usPonCTagPriority" : 7,
+            "usPonSTagPriority" : 7,
+            "dsPonCTagPriority" : 7,
+            "dsPonSTagPriority" : 7,
+            "technologyProfileId" : 65,
+            "downstreamBandwidthProfile" : "VOIP",
+            "upstreamBandwidthProfile" : "TCONT_TYPE1_Fixed8.5Gbps",
+            "isDhcpRequired" : "true",
+            "configuredMacAddress" : "00:50:56:8a:fd:77",
+            "serviceName" : "VOIP"
+          } ]
+        }, {
+          "id" : "ALPHe3d1cea3-1",
+          "nasPortId" : "ALPHe3d1cea3-1",
+          "uniTagList" : [ {
+            "uniTagMatch" : 35,
+            "ponCTag" : 801,
+            "ponSTag" : 111,
+            "usPonCTagPriority" : 0,
+            "usPonSTagPriority" : 0,
+            "dsPonCTagPriority" : 0,
+            "dsPonSTagPriority" : 0,
+            "technologyProfileId" : 64,
+            "downstreamBandwidthProfile" : "High-Speed-Internet",
+            "upstreamBandwidthProfile" : "TCONT_TYPE4_300Mbps_Peak_User1_HSI_Upstream",
+            "isDhcpRequired" : "true",
+            "serviceName" : "HSIA"
+          }, {
+            "uniTagMatch" : 65,
+            "ponCTag" : 444,
+            "ponSTag" : 333,
+            "usPonCTagPriority" : 7,
+            "usPonSTagPriority" : 7,
+            "dsPonCTagPriority" : 7,
+            "dsPonSTagPriority" : 7,
+            "technologyProfileId" : 65,
+            "downstreamBandwidthProfile" : "VOIP",
+            "upstreamBandwidthProfile" : "TCONT_TYPE1_1Mbps_Fixed",
+            "isDhcpRequired" : "true",
+            "configuredMacAddress" : "2c:60:0c:ee:d6:27",
+            "serviceName" : "VOIP"
+          }, {
+            "uniTagMatch" : 55,
+            "ponCTag" : 55,
+            "ponSTag" : 555,
+            "usPonCTagPriority" : 5,
+            "usPonSTagPriority" : 5,
+            "dsPonCTagPriority" : 5,
+            "dsPonSTagPriority" : 5,
+            "technologyProfileId" : 66,
+            "downstreamBandwidthProfile" : "High-Speed-Internet",
+            "upstreamBandwidthProfile" : "TCONT_TYPE2_500Mbps_Assured_ForVoD",
+            "configuredMacAddress" : "2c:60:0c:ee:d6:27",
+            "serviceName" : "VOD",
+            "isDhcpRequired" : "true",
+            "isIgmpRequired" : "true"
+          }, {
+            "ponCTag" : 55,
+            "ponSTag" : 550,
+            "dsPonCTagPriority" : 5,
+            "dsPonSTagPriority" : 5,
+            "technologyProfileId" : 66,
+            "serviceName" : "MC"
+          } ]
+        }, {
+          "id" : "ALPHe3d1ceb7-1",
+          "nasPortId" : "ALPHe3d1ceb7-1",
+          "uniTagList" : [ {
+            "uniTagMatch" : 35,
+            "ponCTag" : 101,
+            "ponSTag" : 222,
+            "usPonCTagPriority" : 0,
+            "usPonSTagPriority" : 0,
+            "dsPonCTagPriority" : 0,
+            "dsPonSTagPriority" : 0,
+            "technologyProfileId" : 64,
+            "downstreamBandwidthProfile" : "High-Speed-Internet",
+            "upstreamBandwidthProfile" : "TCONT_TYPE5_1Gbps_Peak_500Mbps_Assured_200Mbps_Fixed_User1_HSI_Upstream",
+            "isDhcpRequired" : "true",
+            "serviceName" : "HSIA"
+          }, {
+            "uniTagMatch" : 65,
+            "ponCTag" : 444,
+            "ponSTag" : 333,
+            "usPonCTagPriority" : 7,
+            "usPonSTagPriority" : 7,
+            "dsPonCTagPriority" : 7,
+            "dsPonSTagPriority" : 7,
+            "technologyProfileId" : 65,
+            "downstreamBandwidthProfile" : "VOIP",
+            "upstreamBandwidthProfile" : "TCONT_TYPE1_1Mbps_Fixed",
+            "isDhcpRequired" : "true",
+            "configuredMacAddress" : "2c:60:0c:ee:d7:68",
+            "serviceName" : "VOIP"
+          }, {
+            "uniTagMatch" : 55,
+            "ponCTag" : 55,
+            "ponSTag" : 555,
+            "usPonCTagPriority" : 5,
+            "usPonSTagPriority" : 5,
+            "dsPonCTagPriority" : 5,
+            "dsPonSTagPriority" : 5,
+            "technologyProfileId" : 67,
+            "downstreamBandwidthProfile" : "High-Speed-Internet",
+            "upstreamBandwidthProfile" : "TCONT_TYPE3_2Mbps_Peak_1Mbps_Assured_ForVoD",
+            "configuredMacAddress" : "2c:60:0c:ee:d7:68",
+            "serviceName" : "VOD",
+            "isDhcpRequired" : "true",
+            "isIgmpRequired" : "true"
+          }, {
+            "ponCTag" : 55,
+            "ponSTag" : 550,
+            "dsPonCTagPriority" : 5,
+            "dsPonSTagPriority" : 5,
+            "technologyProfileId" : 67,
+            "serviceName" : "MC"
+          } ]
+        }, {
+          "id" : "EC1838000853",
+          "hardwareIdentifier" : "00:00:00:00:00:01",
+          "ipAddress" : "10.192.20.206",
+          "uplinkPort" : "1048576"
+        } ]
+      }
+    },
+    "org.opencord.igmpproxy" : {
+        "igmpproxy":{
+           "FastLeave":"true",
+           "LastQueryInterval":1,
+           "MaxResp":1,
+           "enableIgmpProvisioning":"false",
+           "globalConnectPointMode":"true",
+           "globalConnectPoint" : "of:0000000000000001/3",
+           "sourceDeviceAndPort":"of:0000000000000001/3",
+           "outgoingIgmpVlanId":550,
+           "outgoingIgmpInnerVlanId":55,
+           "outgoingIgmpWithV3":"true",
+           "IgmpCos":5,
+           "IgmpUniCos":5,
+           "PeriodicQuery":"true",
+           "KeepAliveInterval":60,
+           "KeepAliveCount":5,
+           "requestDsIgmpPackets":false
+        }
+    }
+  },
+  "regions" : { },
+  "links" : { },
+  "layouts" : { }
+}
+