aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--examples/pygments_api/tests.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/examples/pygments_api/tests.py b/examples/pygments_api/tests.py
index 0036345c..017823b9 100644
--- a/examples/pygments_api/tests.py
+++ b/examples/pygments_api/tests.py
@@ -1,7 +1,12 @@
from django.test import TestCase
from djangorestframework.compat import RequestFactory
from pygments_api import views
-import tempfile, shutil, json
+import tempfile, shutil
+
+try:
+ import json
+except ImportError:
+ import simplejson as json
class TestPygmentsExample(TestCase):