diff --git a/cachalot/tests/postgres.py b/cachalot/tests/postgres.py index d1a5698..f488935 100644 --- a/cachalot/tests/postgres.py +++ b/cachalot/tests/postgres.py @@ -14,11 +14,11 @@ from django.test import TransactionTestCase, override_settings from psycopg2.extras import NumericRange, DateRange, DateTimeTZRange from pytz import timezone -if django_version[:2] >= (1, 8): +if django_version >= (1, 8): from .models import PostgresModel, Test -@skipUnless(connection.vendor == 'postgresql' and django_version[:2] >= (1, 8), +@skipUnless(connection.vendor == 'postgresql' and django_version >= (1, 8), 'This test is only for PostgreSQL and Django >= 1.8') @skipIf(isinstance(caches['default'], FileBasedCache) and python_version_tuple()[:2] == ('2', '7'),