Fix coverage setup
This commit is contained in:
0
tests/__init__.py
Normal file
0
tests/__init__.py
Normal file
@@ -1,16 +1,9 @@
|
||||
"""pytest config"""
|
||||
"""Tools for files. """
|
||||
|
||||
import os
|
||||
import sys
|
||||
|
||||
__dirname__ = os.path.abspath(os.path.dirname(__file__))
|
||||
|
||||
|
||||
def _file_path(*other):
|
||||
|
||||
return os.path.abspath(os.path.join(__dirname__, *other))
|
||||
|
||||
|
||||
def pytest_configure(config):
|
||||
sys.path.insert(0, _file_path('..'))
|
||||
return config
|
||||
@@ -2,9 +2,10 @@
|
||||
import json
|
||||
import sys
|
||||
|
||||
from conftest import _file_path
|
||||
from fetch_holidays import CustomJSONEncoder, DescriptionParser
|
||||
|
||||
from .filetools import _file_path
|
||||
|
||||
|
||||
def _normalize(iterable):
|
||||
return sorted(json.loads(json.dumps(list(iterable), cls=CustomJSONEncoder)),
|
||||
|
||||
Reference in New Issue
Block a user