aboutsummaryrefslogtreecommitdiffstats
path: root/rest_framework/test.py
diff options
context:
space:
mode:
authorTom Christie2014-08-19 16:15:48 +0100
committerTom Christie2014-08-19 16:15:48 +0100
commit390061bed0991892dfa6c9b953fffc1bd15564a9 (patch)
tree19b77e0e7b2c3559e7a427196364e7d1060b08b5 /rest_framework/test.py
parente385a7b8eb6e538698f28128e43fe8bfaefd4e97 (diff)
parent2d2737f367c241c29c9c3913f2dba986c7c9a4a5 (diff)
downloaddjango-rest-framework-390061bed0991892dfa6c9b953fffc1bd15564a9.tar.bz2
Merge pull request #1780 from tomchristie/pytest-tweaks
Added `runtests.py` and `flake8` code linting.
Diffstat (limited to 'rest_framework/test.py')
-rw-r--r--rest_framework/test.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/rest_framework/test.py b/rest_framework/test.py
index d4ec50a0..9242cf7c 100644
--- a/rest_framework/test.py
+++ b/rest_framework/test.py
@@ -49,9 +49,10 @@ class APIRequestFactory(DjangoRequestFactory):
else:
format = format or self.default_format
- assert format in self.renderer_classes, ("Invalid format '{0}'. "
- "Available formats are {1}. Set TEST_REQUEST_RENDERER_CLASSES "
- "to enable extra request formats.".format(
+ assert format in self.renderer_classes, (
+ "Invalid format '{0}'. Available formats are {1}. "
+ "Set TEST_REQUEST_RENDERER_CLASSES to enable "
+ "extra request formats.".format(
format,
', '.join(["'" + fmt + "'" for fmt in self.renderer_classes.keys()])
)