Cleanup OvsDpdkContextTestCase unit tests 13/59213/1
authorRodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Thu, 28 Jun 2018 16:06:12 +0000 (17:06 +0100)
committerRodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Thu, 28 Jun 2018 16:06:34 +0000 (17:06 +0100)
Removed unneeded output.

JIRA: YARDSTICK-1264

Change-Id: Ic804d5ebd5bc1c0fc8c98c058e8dd76a9ea565fa
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
yardstick/tests/unit/benchmark/contexts/standalone/test_ovs_dpdk.py

index 5be22a0..a4a8359 100644 (file)
@@ -58,7 +58,10 @@ class OvsDpdkContextTestCase(unittest.TestCase):
             'file': self._get_file_abspath(self.NODES_ovs_dpdk_SAMPLE)
         }
         self.ovs_dpdk = ovs_dpdk.OvsDpdkContext()
+        self._mock_log = mock.patch.object(ovs_dpdk, 'LOG')
+        self.mock_log = self._mock_log.start()
         self.addCleanup(self._remove_contexts)
+        self.addCleanup(self._stop_mocks)
 
     @staticmethod
     def _remove_contexts():
@@ -66,6 +69,9 @@ class OvsDpdkContextTestCase(unittest.TestCase):
             context._delete_context()
         base.Context.list = []
 
+    def _stop_mocks(self):
+        self._mock_log.stop()
+
     @mock.patch('yardstick.benchmark.contexts.standalone.model.Server')
     @mock.patch('yardstick.benchmark.contexts.standalone.model.StandaloneContextHelper')
     def test___init__(self, mock_helper, mock_server):