insert local directory into PYTHONPATH when running tests

This commit is contained in:
Mike Fährmann
2020-05-02 01:15:50 +02:00
parent 714566b6e3
commit 5df8f2959b
10 changed files with 72 additions and 45 deletions

View File

@@ -1,15 +1,18 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright 2018 Mike Fährmann
# Copyright 2018-2020 Mike Fährmann
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
import os
import sys
import unittest
from gallery_dl import oauth, text
sys.path.insert(0, os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
from gallery_dl import oauth, text # noqa E402
TESTSERVER = "http://term.ie/oauth/example"
CONSUMER_KEY = "key"