fix: Remove dependency on testtools

Closes #88
This commit is contained in:
kgriffs
2013-03-18 19:29:33 -04:00
parent 9cc8572561
commit d7c2a7a509
5 changed files with 14 additions and 10 deletions

View File

@@ -18,7 +18,7 @@ Falcon is a [high-performance Python framework][home] for building cloud APIs. I
**Fast.** Cloud APIs need to turn around requests quickly, and make efficient use of hardware. Falcon processes requests [several times faster][bench] than other popular web frameworks.
**Light.** Only the essentials are included, with *six* and *testtools* being the only two dependencies outside the standard library. We work to keep the code lean, making Falcon easier to test, optimize, and deploy.
**Light.** Only the essentials are included, with *six* being the only dependency outside the standard library. We work to keep the code lean, making Falcon easier to test, optimize, and deploy.
**Flexible.** Falcon can be deployed in a variety of ways, depending on your needs. The framework speaks WSGI, and works great with [Python 2.6 and 2.7, PyPy, and Python 3.3][ci]. There's no tight coupling with any async framework, leaving you free to mix-and-match what you need.

View File

@@ -19,5 +19,5 @@ limitations under the License.
# Hoist classes and functions into the falcon.testing namespace
from falcon.testing.helpers import * # NOQA
from falcon.testing.srmock import StartResponseMock # NOQA
from falcon.testing.test_resource import TestResource # NOQA
from falcon.testing.resource import TestResource # NOQA
from falcon.testing.base import TestBase # NOQA

View File

@@ -16,16 +16,21 @@ limitations under the License.
"""
import testtools
try:
import testtools as unittest
except ImportError:
import unittest
import falcon
from falcon.testing.srmock import StartResponseMock
from falcon.testing.helpers import create_environ
class TestBase(testtools.TestCase):
class TestBase(unittest.TestCase):
"""Scaffolding around testtools.TestCase for testing a Falcon API endpoint.
Note: If testtools is not available, falls back to using unittest.
Inherit from this and write your test methods. If the child class defines
a before(self) method, this method will be called before executing each
test method. Likewise, child classes may define an after(self) method to

View File

@@ -6,7 +6,7 @@ from setuptools import setup, find_packages, Extension
VERSION = imp.load_source('version', path.join('.', 'falcon', 'version.py'))
VERSION = VERSION.version
REQUIRES = ['six', 'testtools']
REQUIRES = ['six']
if sys.version_info < (2, 7):
REQUIRES.append('ordereddict')

View File

@@ -1,6 +1,5 @@
nose
nose-progressive
testtools
six
cython
ordereddict
nose
ordereddict
six
testtools