Improve SCPF tests
- Add flowObj param to check if test run with FlowObject
- Clean up old FlowObject tests
Change-Id: I04f455983a13a3221306fdde12ff6e9392fe7399
diff --git a/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.params b/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.params
index fe61b9a..8843c2f 100644
--- a/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.params
+++ b/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.params
@@ -18,7 +18,8 @@
<ingress>null:0000000000000001/6</ingress>
<egress>null:0000000000000007/5</egress>
<debug>False</debug>
- </TEST>
+ <flowObj>False</flowObj>
+ </TEST>
<GIT>
<gitPull>off</gitPull>
@@ -26,7 +27,8 @@
</GIT>
<DATABASE>
- <file>/tmp/IntentInstallWithdrawLatDB</file>
+ <dbName>/tmp/IntentInstallWithdrawLatDB</dbName>
+ <dbFlowObj>/tmp/IntentInstallWithdrawLatDBWFO</dbFlowObj>
</DATABASE>
<ATTEMPTS>
<verify>3</verify>
diff --git a/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.py b/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.py
index ef50ab3..3e84aad 100644
--- a/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.py
+++ b/TestON/tests/SCPF/SCPFintentInstallWithdrawLat/SCPFintentInstallWithdrawLat.py
@@ -62,7 +62,6 @@
main.maxNodes = int(main.params['max'])
main.cellName = main.params['ENV']['cellName']
main.scale = (main.params['SCALE']).split(",")
- main.dbFileName = main.params['DATABASE']['file']
main.timeout = int(main.params['SLEEP']['timeout'])
main.startUpSleep = int(main.params['SLEEP']['startup'])
main.installSleep = int(main.params['SLEEP']['install'])
@@ -74,6 +73,15 @@
main.ingress = main.params['TEST']['ingress']
main.egress = main.params['TEST']['egress']
main.debug = main.params['TEST']['debug']
+ main.flowObj = main.params['TEST']['flowObj']
+
+ if main.flowObj == "True":
+ main.flowObj = True
+ main.dbFileName = main.params['DATABASE']['dbFlowObj']
+ else:
+ main.flowObj = False
+ main.dbFileName = main.params['DATABASE']['dbName']
+
for i in range(0, len(main.intentsList)):
main.intentsList[i] = int(main.intentsList[i])
# Create DataBase file
@@ -191,6 +199,9 @@
main.CLIs[0].setCfg("org.onosproject.provider.nil.NullProviders", "topoShape", value="linear")
main.CLIs[0].setCfg("org.onosproject.provider.nil.NullProviders", "enabled", value="true")
main.CLIs[0].setCfg("org.onosproject.net.intent.impl.IntentManager", "skipReleaseResourcesOnWithdrawal", value="true")
+ if main.flowObj:
+ main.CLIs[0].setCfg("org.onosproject.net.intent.impl.compiler.IntentConfigurableRegistrator",
+ "useFlowObjectives", value="true")
time.sleep(main.startUpSleep)
# balanceMasters