Add Stratum support for SRDynamicConf

- Add bmv2 switch support to cord_fabric topo file
- Fix some error handling for SR tests
- Updating testcases to run for SR Stratum tests
- Fix Tost-ONOS docker image tag for onos-2.2
- Update make command for changed variable names
- Fix expected hosts files for SRDhcprelay
    - Fix case 12 config
    - Add config for cases 3 and 4
    - Create generic files

Change-Id: I39d499baaf69eb047e261fd2d6b6f2e846707719
(cherry picked from commit c15b8dfb3093c1b693ea05227ada9a9f1c6d4afb)
diff --git a/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params b/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params
index 460b769..52770f7 100644
--- a/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params
+++ b/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params
@@ -16,7 +16,7 @@
         <useCommonConf>False</useCommonConf>
         <useCommonTopo>True</useCommonTopo>
         <useBmv2>False</useBmv2>
-        <bmv2SwitchType>bmv2</bmv2SwitchType>
+        <bmv2SwitchType>stratum</bmv2SwitchType>
         <stratumRoot>~/stratum</stratumRoot>
         <topology>trellis_fabric.py</topology>
         <lib>routinglib.py,trellislib.py,stratum.py</lib>
diff --git a/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params.stratum b/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params.stratum
index fdbf848..64878d1 100644
--- a/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params.stratum
+++ b/TestON/tests/USECASE/SegmentRouting/SRBridging/SRBridging.params.stratum
@@ -34,7 +34,7 @@
     <CLUSTER>
         # Params for onos docker
         <dockerSkipBuild>True</dockerSkipBuild>
-        <dockerBuildCmd>make ONOS_BRANCH=master DOCKER_TAG=TestON-master onos-build trellis-control-build trellis-t3-build tost-build</dockerBuildCmd> # If using another cmd like make
+        <dockerBuildCmd>make ONOS_VERSION=master DOCKER_TAG=TestON-master onos-build trellis-control-build trellis-t3-build tost-build</dockerBuildCmd> # If using another cmd like make
         <dockerBuildTimeout>1200</dockerBuildTimeout>
         <dockerFilePath>~/tost-onos</dockerFilePath>
         <dockerImageTag>tost:TestON-master</dockerImageTag>
diff --git a/TestON/tests/USECASE/SegmentRouting/SRBridging/dependencies/SRBridgingTest.py b/TestON/tests/USECASE/SegmentRouting/SRBridging/dependencies/SRBridgingTest.py
index a617716..c3d93be 100644
--- a/TestON/tests/USECASE/SegmentRouting/SRBridging/dependencies/SRBridgingTest.py
+++ b/TestON/tests/USECASE/SegmentRouting/SRBridging/dependencies/SRBridgingTest.py
@@ -100,5 +100,5 @@
         except Exception as e:
             main.log.exception( "Error in runTest" )
             main.skipCase( result="FAIL", msg=e )
-
-        run.cleanup( main )
+        finally:
+            run.cleanup( main )