From 70abc1c80797faa5df8aa8163c90e671bdd1d897 Mon Sep 17 00:00:00 2001 From: Brent O'Connor Date: Fri, 12 Sep 2014 13:37:39 -0500 Subject: [PATCH] Fixed tests so they run under Django 1.7 --- .../management/commands/import_categories.py | 2 +- categories/templates/categories/ul_tree.html | 2 +- categories/tests/__init__.py | 4 ---- ...category_import.py => test_category_import.py} | 0 categories/tests/{manager.py => test_manager.py} | 0 .../{registration.py => test_registration.py} | 0 .../{templatetags.py => test_templatetags.py} | 3 +++ example/manage.py | 15 +++++++-------- example/settings.py | 2 ++ example/simpletext/admin.py | 1 + 10 files changed, 15 insertions(+), 14 deletions(-) rename categories/tests/{category_import.py => test_category_import.py} (100%) rename categories/tests/{manager.py => test_manager.py} (100%) rename categories/tests/{registration.py => test_registration.py} (100%) rename categories/tests/{templatetags.py => test_templatetags.py} (97%) diff --git a/categories/management/commands/import_categories.py b/categories/management/commands/import_categories.py index fe63970..f0f164e 100644 --- a/categories/management/commands/import_categories.py +++ b/categories/management/commands/import_categories.py @@ -27,7 +27,7 @@ class Command(BaseCommand): else: return ' ' * indent_amt - @transaction.commit_on_success + @transaction.atomic def make_category(self, string, parent=None, order=1): """ Make and save a category object from a string diff --git a/categories/templates/categories/ul_tree.html b/categories/templates/categories/ul_tree.html index ef77d11..b6013de 100644 --- a/categories/templates/categories/ul_tree.html +++ b/categories/templates/categories/ul_tree.html @@ -1,5 +1,5 @@ {% load category_tags %}{% spaceless %} -