aboutsummaryrefslogtreecommitdiffstats
path: root/conf/integration/01_testcases.conf
blob: a67702f83e8b0bd5fd6f53ea74ee7ad2f2739d17 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
# Copyright 2015-2016 Intel Corporation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

# The 1st value of SUPPORTED_TUNNELING_PROTO is used as the default
# tunneling protocol for OP2P tests.
SUPPORTED_TUNNELING_PROTO = ['vxlan', 'gre', 'geneve']

#
# Generic test configuration options are described at conf/01_testcases.conf
#

#
# Options specific to integration testcases are described below:
#
# Required for OP2P tests
# "Tunnel Type": ["vxlan"|"gre"|"geneve"]   # Tunnel Type defines tunneling protocol to use.
#                                   # It can be overridden by cli option tunnel_type.
#                                   # Values:
#                                   #    "vxlan" - iteration of destination MAC address
#                                   #    "gre" - iteration of destination IP address
#                                   #    "geneve" - iteration of destination UDP port
#                                   # Default value is "vxlan".
#
# biDirectional testing for OP2P is not yet supported.
# biDirectional must be set to False.
#
# "TestSteps": []                   # Definition of integration test steps.
#                                   # In case that this list is defined, then
#                                   # vsperf will execute defined test steps
#                                   # one by one. It can be used to configure
#                                   # vswitch, insert flows and transmit traffic.
#                                   # It is possible to refer to result of any
#                                   # previous step through #STEP[i][j] macro.
#                                   # Where i is a number of step (starts from 0)
#                                   # and j is index of result returned by step i.

#
# Common TestSteps parts ("macros")
#

# P2P macros
STEP_VSWITCH_P2P_FLOWS_INIT = [
    ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
    ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
    ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_P2P_FLOWS_FINIT = [
    ['vswitch', 'dump_flows', 'int_br0'],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
    ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
    ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
    ['vswitch', 'del_switch', 'int_br0'],
]

# PVP and PVVP macros
STEP_VSWITCH_PVP_INIT = [
    ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
    ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
    ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 3    vm1 ports
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 4
]

STEP_VSWITCH_PVP_FINIT = [
    ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
    ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
    ['vswitch', 'del_port', 'int_br0', '#STEP[3][0]'],
    ['vswitch', 'del_port', 'int_br0', '#STEP[4][0]'],
    ['vswitch', 'del_switch', 'int_br0'],
]

STEP_VSWITCH_PVP_FLOWS_INIT = STEP_VSWITCH_PVP_INIT + [
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[3][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_PVP_FLOWS_FINIT = [
    ['vswitch', 'dump_flows', 'int_br0'],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[4][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[3][1]'}],
] + STEP_VSWITCH_PVP_FINIT

STEP_VSWITCH_PVVP_INIT = STEP_VSWITCH_PVP_INIT + [
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 5    vm2 ports
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 6
]

STEP_VSWITCH_PVVP_FINIT = [
    ['vswitch', 'del_port', 'int_br0', '#STEP[5][0]'],  # vm2 ports
    ['vswitch', 'del_port', 'int_br0', '#STEP[6][0]'],
] + STEP_VSWITCH_PVP_FINIT

STEP_VSWITCH_PVVP_FLOWS_INIT = STEP_VSWITCH_PVVP_INIT + [
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[5][1]', 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
    ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[3][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_PVVP_FLOWS_FINIT = [
    ['vswitch', 'dump_flows', 'int_br0'],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[4][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[6][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[5][1]'}],
    ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[3][1]'}],
] + STEP_VSWITCH_PVVP_FINIT

STEP_VSWITCH_2PHY_2VM_INIT = STEP_VSWITCH_PVVP_INIT

STEP_VSWITCH_2PHY_2VM_FINIT = STEP_VSWITCH_PVVP_FINIT

STEP_VSWITCH_2_PARALLEL_VM_FLOWS_INIT  = [
            # Setup Flows to reply ICMPv6 and similar packets, so to
            # avoid flooding the internal port with their re-transmissions
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:01', \
                'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:02', \
                'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:03', \
                'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:04', \
                'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
            # Forward UDP packets depending on dest port
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '0', \
                'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '1', \
                'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
            # Send VM outputs to phy port #2
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_2PHY_4VM_INIT = STEP_VSWITCH_2PHY_2VM_INIT + [
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 7    vm3 ports
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 8
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 9    vm4 ports
    ['vswitch', 'add_vport', 'int_br0'],            # STEP 10
]

STEP_VSWITCH_2PHY_4VM_FINIT = [
    ['vswitch', 'del_port', 'int_br0', '#STEP[7][0]'],  # vm3 ports
    ['vswitch', 'del_port', 'int_br0', '#STEP[8][0]'],
    ['vswitch', 'del_port', 'int_br0', '#STEP[9][0]'],  # vm4 ports
    ['vswitch', 'del_port', 'int_br0', '#STEP[10][0]'],
] + STEP_VSWITCH_2PHY_2VM_FINIT

STEP_VSWITCH_FLOWS_FINIT = [
    ['vswitch', 'dump_flows', 'int_br0'],
    ['vswitch', 'del_flow', 'int_br0'],
]

STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT = [
            # Setup Flows to reply ICMPv6 and similar packets, so to
            # avoid flooding the internal port with their re-transmissions
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:01', \
                'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:02', \
                'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:03', \
                'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:04', \
                'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:05', \
                'actions': ['output:#STEP[7][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:06', \
                'actions': ['output:#STEP[8][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:07', \
                'actions': ['output:#STEP[9][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:08', \
                'actions': ['output:#STEP[10][1]'], 'idle_timeout': '0'}],
            # Forward UDP packets depending on dest port
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '0', \
                'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '1', \
                'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '2', \
                'actions': ['output:#STEP[7][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '3', \
                'actions': ['output:#STEP[9][1]'], 'idle_timeout': '0'}],
            # Send VM outputs to phy port #2
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[8][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[10][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_2PHY_6VM_INIT = STEP_VSWITCH_2PHY_4VM_INIT + [
            ['vswitch', 'add_vport', 'int_br0'],        # STEP 11   vm5    vhu8
            ['vswitch', 'add_vport', 'int_br0'],        # STEP 12          vhu9
            ['vswitch', 'add_vport', 'int_br0'],        # STEP 13   vm6    vhu10
            ['vswitch', 'add_vport', 'int_br0'],        # STEP 14          vhu11
]

STEP_VSWITCH_6_PARALLEL_VM_FLOWS_INIT = STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT + [
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:09', \
                'actions': ['output:#STEP[11][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:0a', \
                'actions': ['output:#STEP[12][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:0b', \
                'actions': ['output:#STEP[13][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', \
                {'priority': '1', 'dl_src': '00:00:00:00:00:0c', \
                'actions': ['output:#STEP[14][1]'], 'idle_timeout': '0'}],
            # Forward UDP packets depending on dest port
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '4', \
                'actions': ['output:#STEP[11][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
                'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '5', \
                'actions': ['output:#STEP[13][1]'], 'idle_timeout': '0'}],
            # Send VM outputs to phy port #2
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[12][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
            ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[14][1]', \
                'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
]

STEP_VSWITCH_2PHY_6VM_FINIT = [
            ['vswitch', 'del_port', 'int_br0', '#STEP[11][0]'],  # vm5 ports
            ['vswitch', 'del_port', 'int_br0', '#STEP[12][0]'],
            ['vswitch', 'del_port', 'int_br0', '#STEP[13][0]'],  # vm6 ports
            ['vswitch', 'del_port', 'int_br0', '#STEP[14][0]'],
] + STEP_VSWITCH_2PHY_4VM_FINIT

#
# Definition of integration tests
#
INTEGRATION_TESTS = [
    {
        "Name": "overlay_p2p_mod_tput",
        "Traffic Type": "rfc2544",
        "Deployment": "ptunp",
        "biDirectional": 'True',
        "Tunnel Type": "vxlan",
        "Description": ("Tunneling Throughput RFC2544 Test."
                       "The encap and decap are performed inside the "
                       "virtual switch itself in each direction to avoid "
                       "the need of ingress overlay traffic."),
    },
    {
        "Name": "overlay_p2p_tput",
        "Traffic Type": "rfc2544",
        "Deployment": "op2p",
        "biDirectional": 'False',
        "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
        "Tunnel Operation": "encapsulation",
        "Description": "Overlay Encapsulation Throughput RFC2544 Test",
    },
    {
        "Name": "overlay_p2p_cont",
        "Traffic Type": "continuous",
        "Deployment": "op2p",
        "biDirectional": 'False',
        "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
        "Tunnel Operation": "encapsulation",
        "Description": "Overlay Encapsulation Continuous Stream",
    },
    {
        "Name": "overlay_p2p_decap_tput",
        "Traffic Type": "rfc2544",
        "Deployment": "op2p",
        "biDirectional": 'False',
        "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
        "Tunnel Operation": "decapsulation",
        "Description": "Overlay Decapsulation Throughput RFC2544 Test",
    },
    {
        "Name": "overlay_p2p_decap_cont",
        "Traffic Type": "continuous",
        "Deployment": "op2p",
        "biDirectional": 'False',
        "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
        "Tunnel Operation": "decapsulation",
        "Description": "Overlay Decapsulation Continuous Stream",
    },
    {
        "Name": "vswitch_add_del_bridge",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete bridge",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_bridges",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete bridges",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_switch', 'int_br1'],
                        ['vswitch', 'del_switch', 'int_br0'],
                        ['vswitch', 'del_switch', 'int_br1'],
                     ]
    },
    {
        "Name": "vswitch_add_del_phy_port",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete physical port",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_phy_port', 'int_br0'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_phy_ports",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete physical ports",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_phy_port', 'int_br0'],
                        ['vswitch', 'add_phy_port', 'int_br0'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_vport",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete virtual port",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_vport', 'int_br0'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_vports",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete virtual ports",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_vport', 'int_br0'],
                        ['vswitch', 'add_vport', 'int_br0'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_flow",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete flow",
        "TestSteps": [
                        ['vswitch', 'add_switch', 'int_br0'],
                        ['vswitch', 'add_phy_port', 'int_br0'],
                        ['vswitch', 'add_phy_port', 'int_br0'],
                        ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
                        ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
                        ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
                        ['vswitch', 'del_switch', 'int_br0'],
                     ]
    },
    {
        "Name": "vswitch_add_del_flows",
        "Deployment": "clean",
        "Description": "vSwitch - add and delete flows",
        "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
                     STEP_VSWITCH_P2P_FLOWS_FINIT
    },
    {
        "Name": "vswitch_p2p_tput",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch and execute RFC2544 throughput test",
        "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
                     [
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'throughput', 'bidir' : 'True'}],
                     ] +
                     STEP_VSWITCH_P2P_FLOWS_FINIT
    },
    {
        "Name": "vswitch_p2p_back2back",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch and execute RFC2544 back2back test",
        "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
                     [
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'back2back', 'bidir' : 'True'}],
                     ] +
                     STEP_VSWITCH_P2P_FLOWS_FINIT
    },
    {
        "Name": "vswitch_p2p_cont",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch and execute continuous stream test",
        "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
                     [
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
                     ] +
                     STEP_VSWITCH_P2P_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvp",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch and one vnf",
        "TestSteps": STEP_VSWITCH_PVP_INIT +
                     [
                        ['vnf', 'start'],
                        ['vnf', 'stop'],
                     ] +
                     STEP_VSWITCH_PVP_FINIT
    },
    {
        "Name": "vswitch_pvp_tput",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, vnf and execute RFC2544 throughput test",
        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
                     [
                        ['vnf', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'throughput', 'bidir' : 'True'}],
                        ['vnf', 'stop'],
                     ] +
                     STEP_VSWITCH_PVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvp_back2back",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, vnf and execute RFC2544 back2back test",
        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
                     [
                        ['vnf', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'back2back', 'bidir' : 'True'}],
                        ['vnf', 'stop'],
                     ] +
                     STEP_VSWITCH_PVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvp_cont",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, vnf and execute continuous stream test",
        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
                     [
                        ['vnf', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
                        ['vnf', 'stop'],
                     ] +
                     STEP_VSWITCH_PVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvp_all",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, vnf and execute all test types",
        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
                     [
                        ['vnf', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'throughput', 'bidir' : 'True'}],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'back2back', 'bidir' : 'True'}],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
                        ['vnf', 'stop'],
                     ] +
                     STEP_VSWITCH_PVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvvp",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch and two vnfs",
        "TestSteps": STEP_VSWITCH_PVVP_INIT +
                     [
                        ['vnf1', 'start'],
                        ['vnf2', 'start'],
                        ['vnf1', 'stop'],
                        ['vnf2', 'stop'],
                     ] +
                     STEP_VSWITCH_PVVP_FINIT
    },
    {
        "Name": "vswitch_pvvp_tput",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, two chained vnfs and execute RFC2544 throughput test",
        "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
                     [
                        ['vnf1', 'start'],
                        ['vnf2', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'throughput', 'bidir' : 'True'}],
                        ['vnf1', 'stop'],
                        ['vnf2', 'stop'],
                     ] +
                     STEP_VSWITCH_PVVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvvp_back2back",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, two chained vnfs and execute RFC2544 back2back test",
        "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
                     [
                        ['vnf1', 'start'],
                        ['vnf2', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'back2back', 'bidir' : 'True'}],
                        ['vnf1', 'stop'],
                        ['vnf2', 'stop'],
                     ] +
                     STEP_VSWITCH_PVVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvvp_cont",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, two chained vnfs and execute continuous stream test",
        "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
                     [
                        ['vnf1', 'start'],
                        ['vnf2', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
                        ['vnf1', 'stop'],
                        ['vnf2', 'stop'],
                     ] +
                     STEP_VSWITCH_PVVP_FLOWS_FINIT
    },
    {
        "Name": "vswitch_pvvp_all",
        "Deployment": "clean",
        "Description": "vSwitch - configure switch, two chained vnfs and execute all test types",
        "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
                     [
                        ['vnf1', 'start'],
                        ['vnf2', 'start'],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'throughput', 'bidir' : 'True'}],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'back2back', 'bidir' : 'True'}],
                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
                        ['vnf1', 'stop'],
                        ['vnf2', 'stop'],
                     ] +
                     STEP_VSWITCH_PVVP_FLOWS_FINIT
    },
    {
      # Topology: 2 Parallel PVP connections
      # To run a Linux bridge as a loopback in the Guest use:
      #     --test-params "guest_loopback=linux_bridge" --integration 2pvp_udp_dest_flows
        "Name": "2pvp_udp_dest_flows",
        "Description": "Continuous TC with 2 Parallel VMs, flows on UDP Dest Port",
        "Deployment": "clean",
        "Stream Type": "L4",
        "MultiStream": 2,
        "TestSteps": STEP_VSWITCH_2PHY_2VM_INIT +
            STEP_VSWITCH_2_PARALLEL_VM_FLOWS_INIT + [
            # Start 2 VMs
            ['vnf1', 'start'],
            ['vnf2', 'start'],
            ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'False'}],
            ['vnf1', 'stop'],
            ['vnf2', 'stop'],
            # Clean up
        ] + STEP_VSWITCH_FLOWS_FINIT +
            STEP_VSWITCH_2PHY_2VM_FINIT
    },
    {
      # Topology: 4 Parallel PVP connections
      # To run a Linux bridge as a loopback in the Guest use:
      #     --test-params "guest_loopback=linux_bridge" --integration 4pvp_udp_dest_flows
        "Name": "4pvp_udp_dest_flows",
        "Description": "Continuous TC with 4 Parallel VMs, flows on UDP Dest Port",
        "Deployment": "clean",
        "Stream Type": "L4",
        "MultiStream": 4,
        "TestSteps": STEP_VSWITCH_2PHY_4VM_INIT +
            STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT + [
            # Start 4 VMs
            ['vnf1', 'start'],
            ['vnf2', 'start'],
            ['vnf3', 'start'],
            ['vnf4', 'start'],
            ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'False'}],
            ['vnf1', 'stop'],
            ['vnf2', 'stop'],
            ['vnf3', 'stop'],
            ['vnf4', 'stop'],
            # Clean up
        ] + STEP_VSWITCH_FLOWS_FINIT +
            STEP_VSWITCH_2PHY_4VM_FINIT
    },
    {
      # Topology: 6 Parallel PVP connections
      # To run a Linux bridge as a loopback in the Guest use:
      #     --test-params "guest_loopback=linux_bridge" --integration 6pvp_udp_dest_flows
        "Name": "6pvp_udp_dest_flows",
        "Description": "Continuous TC with 6 Parallel VMs, flows on UDP Dest Port",
        "Deployment": "clean",
        "Stream Type": "L4",
        "MultiStream": 6,
        "TestSteps": STEP_VSWITCH_2PHY_6VM_INIT +
            STEP_VSWITCH_6_PARALLEL_VM_FLOWS_INIT + [
            # Start VMs
            ['vnf1', 'start'],
            ['vnf2', 'start'],
            ['vnf3', 'start'],
            ['vnf4', 'start'],
            ['vnf5', 'start'],
            ['vnf6', 'start'],
            ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'False'}],
            ['vnf1', 'stop'],
            ['vnf2', 'stop'],
            ['vnf3', 'stop'],
            ['vnf4', 'stop'],
            ['vnf5', 'stop'],
            ['vnf6', 'stop'],
        ] + STEP_VSWITCH_FLOWS_FINIT +
        STEP_VSWITCH_2PHY_6VM_FINIT
    },
]

# Example of TC definition with exact vSwitch, VNF and TRAFFICGEN values.
#    {
#        "Name": "ovs_vanilla_linux_bridge_pvp_cont",
#        "Deployment": "clean",
#        "Description": "vSwitch - configure OVS Vanilla, QemuVirtioNet with linux bridge and execute continuous stream test",
#        "vSwitch" : "OvsVanilla",
#        "VNF" : "QemuVirtioNet",
#        "Trafficgen": "IxNet",
#        "Parameters": {"guest_loopback" : "linux_bridge"},
#        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
#                     [
#                        ['vnf', 'start'],
#                        ['trafficgen', 'send_traffic', {'traffic_type' : 'continuous', 'bidir' : 'True'}],
#                        ['vnf', 'stop'],
#                     ] +
#                     STEP_VSWITCH_PVP_FLOWS_FINIT
#    },