diff options
Diffstat (limited to 'tests/test_from_fixtures.py')
-rw-r--r-- | tests/test_from_fixtures.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/test_from_fixtures.py b/tests/test_from_fixtures.py index 70d6553..d6c9810 100644 --- a/tests/test_from_fixtures.py +++ b/tests/test_from_fixtures.py @@ -1,3 +1,4 @@ +import io import json import os.path @@ -12,7 +13,7 @@ def fixture_file_path(filename): def load_examples(filename): path = fixture_file_path(filename) - with open(path, 'r') as examples_file: + with io.open(path, 'r', encoding="utf-8") as examples_file: examples = json.load(examples_file) return examples @@ -20,7 +21,7 @@ def load_examples(filename): def expected_set(expected): if isinstance(expected, list): return set(expected) - return set([expected]) + return {expected} class FixtureMixin(object): |