Move tests from the test dir into wsgi_intercept/tests

This helps to insure the tests are included with the package
and to avoid conflicting with other packages.
This commit is contained in:
Chris Dent 2016-09-22 19:59:18 +01:00
parent 2504de1f73
commit 4f9294ca2a
14 changed files with 13 additions and 14 deletions

View File

@ -1,3 +1,2 @@
include LICENSE Makefile
recursive-include test *
recursive-include docs *

View File

@ -6,7 +6,7 @@ envlist = py27,py33,py34,py35,pypy,pep8,docs
[testenv]
deps = .[testing]
usedevelop = True
commands = py.test test
commands = py.test wsgi_intercept/tests
passenv = WSGI_INTERCEPT_*
[testenv:pep8]

View File

@ -1,7 +1,7 @@
import py.test
from wsgi_intercept import http_client_intercept, WSGIAppError
from test import wsgi_app
from test.install import installer_class, skipnetwork
from . import wsgi_app
from .install import installer_class, skipnetwork
try:
import http.client as http_lib
except ImportError:

View File

@ -1,7 +1,7 @@
import py.test
from wsgi_intercept import httplib2_intercept, WSGIAppError
from test import wsgi_app
from test.install import installer_class
from . import wsgi_app
from .install import installer_class
import httplib2
from socket import gaierror

View File

@ -1,8 +1,8 @@
import os
import py.test
from wsgi_intercept import requests_intercept, WSGIAppError
from test import wsgi_app
from test.install import installer_class, skipnetwork
from . import wsgi_app
from .install import installer_class, skipnetwork
import requests
from requests.exceptions import ConnectionError

View File

@ -1,8 +1,8 @@
import os
import py.test
from wsgi_intercept import urllib_intercept, WSGIAppError
from test import wsgi_app
from test.install import installer_class, skipnetwork
from . import wsgi_app
from .install import installer_class, skipnetwork
try:
import urllib.request as url_lib
except ImportError:

View File

@ -1,8 +1,8 @@
import os
import py.test
from wsgi_intercept import urllib3_intercept, WSGIAppError
from test import wsgi_app
from test.install import installer_class, skipnetwork
from . import wsgi_app
from .install import installer_class, skipnetwork
import urllib3
HOST = 'some_hopefully_nonexistant_domain'

View File

@ -5,8 +5,8 @@ try:
except ImportError:
from urllib import unquote
from wsgi_intercept import httplib2_intercept
from test import wsgi_app
from test.install import installer_class
from . import wsgi_app
from .install import installer_class
import httplib2
HOST = 'some_hopefully_nonexistant_domain'