blob: 146e72ecccd76a5b10572f9da2135055c821427c [file] [log] [blame]
Devin Limf5175192018-05-14 19:13:22 -07001// Copyright 2017 Open Networking Foundation (ONF)
2//
3// Please refer questions to either the onos test mailing list at <onos-test@onosproject.org>,
4// the System Testing Plans and Results wiki page at <https://wiki.onosproject.org/x/voMg>,
5// or the System Testing Guide page at <https://wiki.onosproject.org/x/WYQg>
6//
7// TestON is free software: you can redistribute it and/or modify
8// it under the terms of the GNU General Public License as published by
9// the Free Software Foundation, either version 2 of the License, or
10// (at your option) any later version.
11//
12// TestON is distributed in the hope that it will be useful,
13// but WITHOUT ANY WARRANTY; without even the implied warranty of
14// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15// GNU General Public License for more details.
16//
17// You should have received a copy of the GNU General Public License
18// along with TestON. If not, see <http://www.gnu.org/licenses/>.
19
20// This is the Jenkins script for manual-graph-generator-SCPF
21
Devin Lim61643762017-12-07 15:55:38 -080022#!groovy
Devin Limf5175192018-05-14 19:13:22 -070023
24// read and set the functions from dependcies.
Devin Limb734ea52018-05-14 14:13:05 -070025SCPFfuncs = evaluate readTrusted( 'TestON/JenkinsFile/dependencies/PerformanceFuncs.groovy' )
Devin Lim61643762017-12-07 15:55:38 -080026SCPFfuncs.init()
Devin Limb734ea52018-05-14 14:13:05 -070027funcs = evaluate readTrusted( 'TestON/JenkinsFile/dependencies/JenkinsCommonFuncs.groovy' )
Devin Lim61643762017-12-07 15:55:38 -080028funcs.initialize( "SCPF", SCPFfuncs );
29
30def prop = null
31prop = funcs.getProperties()
32
Devin Limf5175192018-05-14 19:13:22 -070033// get the variables from the Jenkins parameters.
Devin Lim61643762017-12-07 15:55:38 -080034def Tests = params.Test
35isOldFlow = params.isOldFlow
36prop[ "ONOSBranch" ] = params.ONOSbranch
37
38SCPFfuncs.oldFlowRuleCheck( isOldFlow, prop[ "ONOSBranch" ] )
39
40def testsToRun = null
41testsToRun = funcs.getTestsToRun( Tests )
42
Devin Limf5175192018-05-14 19:13:22 -070043// pureTestName is because we don't want 'WFobj' to be used for test name.
Devin Lim61643762017-12-07 15:55:38 -080044def tests = [:]
45for( String test : testsToRun ){
46 println test
47 pureTestName = test.replaceAll( "WithFlowObj", "" )
48 tests[ test ] = funcs.runTest( test, true, prop, pureTestName, true, [], "", "" )
49}
50
Devin Limf5175192018-05-14 19:13:22 -070051// generate the graphs sequentially.
52parallel tests
53//for ( test in tests.keySet() ){
54// tests[ test ].call()
55//}