It avoids creating a dummy functest.log for unit testing.
Change-Id: Ib163d5d58284822b1904444fb60b08e92ee0ab9b
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
from git.exc import NoSuchPathError
import mock
+mock.patch('logging.FileHandler').start() # noqa
from functest.cli.commands import cli_env
from functest.utils.constants import CONST
from functest.tests.unit import test_utils
import mock
import unittest
+mock.patch('logging.FileHandler').start() # noqa
from functest.core import testcase_base
from robot.errors import RobotError
from robot.result import testcase
+mock.patch('logging.FileHandler').start() # noqa
from functest.core import testcase_base
from functest.opnfv_tests.sdn.odl import odl
import requests
from functest.tests.unit import test_utils
+mock.patch('logging.FileHandler').start() # noqa
from functest.utils import functest_utils
# TODO clean that...
# Create log dir if needed
# log shall be disabled during unit tests
-# fix to be done in Logger
-echo "Create dummy log file...."
sudo mkdir -p /home/opnfv/functest/results/odl
-sudo touch /home/opnfv/functest/results/functest.log
sudo touch /home/opnfv/functest/results/odl/stdout.txt
sudo chmod -Rf a+rw /home/opnfv