summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorVincenzo Riccobene <vincenzox.m.riccobene@intel.com>2016-01-11 09:45:04 +0000
committerJörgen Karlsson <jorgen.w.karlsson@ericsson.com>2016-01-11 16:39:11 +0000
commitbde7eae17a1fc9ec163451b8d62825daa2fec297 (patch)
tree2f2919a30c096e5ad4a73073d79851c0613f6921 /tests
parent5da3bbf2eb241b4550b8397b767123698bc3432a (diff)
Implementation of yardstick-tc007 in Yardstick
Includes - Yardstick Scenario for integration with ApexLake - Yardstick Task .yaml file - Documentation JIRA: YARDSTICK-219 Change-Id: Ifa2555336098e68d0fad8045e2f759aed587ad92 Signed-off-by: Vincenzo Riccobene <vincenzox.m.riccobene@intel.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc007.yaml32
-rw-r--r--tests/unit/benchmark/scenarios/networking/test_vtc_throughput_noisy_test.py51
2 files changed, 83 insertions, 0 deletions
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc007.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc007.yaml
new file mode 100644
index 000000000..30d59f797
--- /dev/null
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc007.yaml
@@ -0,0 +1,32 @@
+---
+# Sample benchmark task config file
+# vTC
+
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: vtc_throughput_noisy
+
+ options:
+ packet_size: 1280
+ vlan_sender: 1007
+ vlan_receiver: 1006
+ default_net_name: monitoring
+ default_subnet_name: monitoring_subnet
+ vlan_net_1_name: inbound_traffic_network
+ vlan_subnet_1_name: inbound_traffic_subnet
+ vlan_net_2_name: inbound_traffic_network
+ vlan_subnet_2_name: inbound_traffic_subnet
+ vnic_type: direct # [normal (OvS), direct (SR-IOV)]
+ vtc_flavor: m1.large
+ num_of_neighbours: 2
+ amount_of_ram: 1G
+ number_of_cores: 2
+
+ runner:
+ type: Iteration
+ iterations: 1
+
+context:
+ type: Dummy
diff --git a/tests/unit/benchmark/scenarios/networking/test_vtc_throughput_noisy_test.py b/tests/unit/benchmark/scenarios/networking/test_vtc_throughput_noisy_test.py
new file mode 100644
index 000000000..98957b1de
--- /dev/null
+++ b/tests/unit/benchmark/scenarios/networking/test_vtc_throughput_noisy_test.py
@@ -0,0 +1,51 @@
+#!/usr/bin/env python
+
+##############################################################################
+# Copyright (c) 2015 Ericsson AB and others.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+# Unittest for yardstick.benchmark.scenarios.networking.iperf3.Iperf
+
+import mock
+import unittest
+
+from yardstick.benchmark.scenarios.networking import vtc_throughput_noisy
+
+
+class VtcThroughputNoisyTestCase(unittest.TestCase):
+
+ def setUp(self):
+ scenario = dict()
+ scenario['options'] = dict()
+ scenario['options']['default_net_name'] = ''
+ scenario['options']['default_subnet_name'] = ''
+ scenario['options']['vlan_net_1_name'] = ''
+ scenario['options']['vlan_subnet_1_name'] = ''
+ scenario['options']['vlan_net_2_name'] = ''
+ scenario['options']['vlan_subnet_2_name'] = ''
+ scenario['options']['vnic_type'] = ''
+ scenario['options']['vtc_flavor'] = ''
+ scenario['options']['packet_size'] = ''
+ scenario['options']['vlan_sender'] = ''
+ scenario['options']['vlan_receiver'] = ''
+ scenario['options']['num_of_neighbours'] = '1'
+ scenario['options']['amount_of_ram'] = '1G'
+ scenario['options']['number_of_cores'] = '1'
+
+ self.vt = vtc_throughput_noisy.VtcThroughputNoisy(scenario, '')
+
+ def test_run_for_success(self):
+ result = {}
+ self.vt.run(result)
+
+
+def main():
+ unittest.main()
+
+if __name__ == '__main__':
+ main()