diff options
| author | tom christie tom@tomchristie.com | 2011-02-04 21:52:21 +0000 |
|---|---|---|
| committer | tom christie tom@tomchristie.com | 2011-02-04 21:52:21 +0000 |
| commit | fcd7f414c407c8dab7c0badbfa16476826dad3ae (patch) | |
| tree | 4d532d354e5f63b0ab31212d2dfc26d937c2720d /djangorestframework/tests/response.py | |
| parent | eebcdc4dc0e3b34fa76eca638c469b1e79240844 (diff) | |
| download | django-rest-framework-fcd7f414c407c8dab7c0badbfa16476826dad3ae.tar.bz2 | |
Huge stack of refactoring getting stuff into Mixin classes, and loads of tests. Kickass.
Diffstat (limited to 'djangorestframework/tests/response.py')
| -rw-r--r-- | djangorestframework/tests/response.py | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/djangorestframework/tests/response.py b/djangorestframework/tests/response.py new file mode 100644 index 00000000..c199f300 --- /dev/null +++ b/djangorestframework/tests/response.py @@ -0,0 +1,25 @@ +from django.test import TestCase +from djangorestframework.response import Response + +try: + import unittest2 +except: + unittest2 = None +else: + import warnings + warnings.filterwarnings("ignore") + +if unittest2: + class TestResponse(TestCase, unittest2.TestCase): + + # Interface tests + + # This is mainly to remind myself that the Response interface needs to change slightly + @unittest2.expectedFailure + def test_response_interface(self): + """Ensure the Response interface is as expected.""" + response = Response() + getattr(response, 'status') + getattr(response, 'content') + getattr(response, 'headers') + |
