mirror of
https://github.com/mikf/gallery-dl.git
synced 2024-11-22 02:32:33 +01:00
[tests] load results from ${GDL_TEST_RESULTS} (#5262)
This commit is contained in:
parent
3b26748264
commit
3eba1f7c29
@ -17,7 +17,7 @@ import string
|
||||
from datetime import datetime, timedelta
|
||||
|
||||
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
|
||||
from gallery_dl import extractor # noqa E402
|
||||
from gallery_dl import extractor, util # noqa E402
|
||||
from gallery_dl.extractor import mastodon # noqa E402
|
||||
from gallery_dl.extractor.common import Extractor, Message # noqa E402
|
||||
from gallery_dl.extractor.directlink import DirectlinkExtractor # noqa E402
|
||||
@ -25,7 +25,11 @@ from gallery_dl.extractor.directlink import DirectlinkExtractor # noqa E402
|
||||
_list_classes = extractor._list_classes
|
||||
|
||||
try:
|
||||
from test import results
|
||||
RESULTS = os.environ.get("GDL_TEST_RESULTS")
|
||||
if RESULTS:
|
||||
results = util.import_file(RESULTS)
|
||||
else:
|
||||
from test import results
|
||||
except ImportError:
|
||||
results = None
|
||||
|
||||
|
@ -20,7 +20,13 @@ import collections
|
||||
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
|
||||
from gallery_dl import \
|
||||
extractor, util, job, config, exception, formatter # noqa E402
|
||||
from test import results # noqa E402
|
||||
|
||||
|
||||
RESULTS = os.environ.get("GDL_TEST_RESULTS")
|
||||
if RESULTS:
|
||||
results = util.import_file(RESULTS)
|
||||
else:
|
||||
from test import results
|
||||
|
||||
|
||||
# temporary issues, etc.
|
||||
|
Loading…
Reference in New Issue
Block a user