diff --git a/tests/helpers/test_logfail.py b/tests/helpers/test_logfail.py index 9873b5ade..2acbdd193 100644 --- a/tests/helpers/test_logfail.py +++ b/tests/helpers/test_logfail.py @@ -30,13 +30,11 @@ import pytest_capturelog # pylint: disable=import-error pytest_plugins = 'pytester' - - @pytest.fixture def log_testdir(testdir): """Testdir which uses our logfail.py as a conftest.""" log_fn = os.path.join(os.path.dirname(__file__), 'logfail.py') - with open(log_fn) as f: + with open(log_fn, encoding='utf-8') as f: testdir.makeconftest(f.read()) return testdir