diff options
Diffstat (limited to 'tests/unit/cmd')
-rw-r--r-- | tests/unit/cmd/commands/test_testcase.py | 8 | ||||
-rw-r--r-- | tests/unit/cmd/test_NSBperf.py | 3 |
2 files changed, 10 insertions, 1 deletions
diff --git a/tests/unit/cmd/commands/test_testcase.py b/tests/unit/cmd/commands/test_testcase.py index 515784352..7ef157c19 100644 --- a/tests/unit/cmd/commands/test_testcase.py +++ b/tests/unit/cmd/commands/test_testcase.py @@ -1,3 +1,11 @@ +############################################################################## +# Copyright (c) 2017 Huawei Technologies Co.,Ltd 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 +############################################################################## import unittest from mock import patch diff --git a/tests/unit/cmd/test_NSBperf.py b/tests/unit/cmd/test_NSBperf.py index a14c08464..5bd248a84 100644 --- a/tests/unit/cmd/test_NSBperf.py +++ b/tests/unit/cmd/test_NSBperf.py @@ -40,7 +40,8 @@ class TestYardstickNSCli(unittest.TestCase): def test_generate_final_report(self): yardstick_ns_cli = YardstickNSCli() test_case = "tc_baremetal_rfc2544_ipv4_1flow_1518B.yaml" - subprocess.call(["touch", "/tmp/yardstick.out"]) + if os.path.isfile("/tmp/yardstick.out"): + os.remove('/tmp/yardstick.out') self.assertIsNone(yardstick_ns_cli.generate_final_report(test_case)) def test_generate_kpi_results(self): |