From 730fb593ad19731e7018dd83236318bfe71de86a Mon Sep 17 00:00:00 2001 From: Tim Graham Date: Mon, 16 Feb 2015 12:11:39 -0500 Subject: [1.8.x] Fixed #24335 -- Bumped required psycopg2 version to 2.4.5 (2.5 for contrib.postgres). Backport of 3adc5f1ee6618a615db07d4a868b366a15c39f82 from master --- tests/backends/tests.py | 6 +++--- tests/requirements/postgres.txt | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/backends/tests.py b/tests/backends/tests.py index edc4783f0e..a624bf57b2 100644 --- a/tests/backends/tests.py +++ b/tests/backends/tests.py @@ -290,14 +290,14 @@ class PostgreSQLTests(TestCase): self.assertIn('::text', do.lookup_cast(lookup)) def test_correct_extraction_psycopg2_version(self): - from django.db.backends.postgresql_psycopg2.base import DatabaseWrapper + from django.db.backends.postgresql_psycopg2.base import psycopg2_version version_path = 'django.db.backends.postgresql_psycopg2.base.Database.__version__' with mock.patch(version_path, '2.6.9'): - self.assertEqual(DatabaseWrapper.psycopg2_version.__get__(self), (2, 6, 9)) + self.assertEqual(psycopg2_version(), (2, 6, 9)) with mock.patch(version_path, '2.5.dev0'): - self.assertEqual(DatabaseWrapper.psycopg2_version.__get__(self), (2, 5)) + self.assertEqual(psycopg2_version(), (2, 5)) class DateQuotingTest(TestCase): diff --git a/tests/requirements/postgres.txt b/tests/requirements/postgres.txt index 658130bb2c..4ff5f170a9 100644 --- a/tests/requirements/postgres.txt +++ b/tests/requirements/postgres.txt @@ -1 +1 @@ -psycopg2 +psycopg2>=2.5 -- cgit v1.3