From 35c0afbb3e78db9e9ac0dc4c536352b33690f3b3 Mon Sep 17 00:00:00 2001 From: Nikolai Kristiansen Date: Sun, 4 Oct 2015 14:21:43 +0200 Subject: [PATCH] Keep python 2 working --- mdb/models.py | 1 - mdb/tests.py | 8 ++++---- mdbsite/__init__.py | 0 3 files changed, 4 insertions(+), 5 deletions(-) create mode 100644 mdbsite/__init__.py diff --git a/mdb/models.py b/mdb/models.py index de99e47..332505f 100644 --- a/mdb/models.py +++ b/mdb/models.py @@ -415,7 +415,6 @@ class DhcpOption(models.Model): verbose_name = 'DHCP option' -@python_2_unicode_compatible class DhcpCustomField(models.Model): value = models.CharField(max_length=255) ip4subnet = models.ForeignKey(Ip4Subnet) diff --git a/mdb/tests.py b/mdb/tests.py index 7581525..98f16ae 100644 --- a/mdb/tests.py +++ b/mdb/tests.py @@ -1,8 +1,8 @@ +import io from django.contrib.auth.models import User from django.core.management import call_command from django.core.urlresolvers import reverse -from django.test import TestCase, LiveServerTestCase -from django.utils import six +from django.test import TestCase from rest_framework.authtoken.models import Token from rest_framework.test import APITestCase @@ -45,12 +45,12 @@ class RunManagementCommands(TestCase): def test_zone_sync(self): expected_zone_file = '' - with six.BytesIO() as f: + with io.BytesIO() as f: call_command('zone-sync', debug=True, stdout=f) # TODO check expected_zone_file def test_dhcp_sync(self): expected_dhcp_file = '' - with six.BytesIO() as f: + with io.BytesIO() as f: call_command('dhcp-sync', ('--debug',), stdout=f) # TODO check expected_dhcp_file diff --git a/mdbsite/__init__.py b/mdbsite/__init__.py new file mode 100644 index 0000000..e69de29