Fixed #32292 -- Added support for connection by service name to PostgreSQL.

This commit is contained in:
Hasan Ramezani 2020-12-23 23:39:43 +01:00 committed by Mariusz Felisiak
parent f054468cac
commit dcb3ad3319
6 changed files with 92 additions and 7 deletions

View file

@ -67,6 +67,12 @@ class PostgreSqlDbshellCommandTestCase(SimpleTestCase):
)
)
def test_service(self):
self.assertEqual(
self.settings_to_cmd_args_env({'OPTIONS': {'service': 'django_test'}}),
(['psql', 'postgres'], {'PGSERVICE': 'django_test'}),
)
def test_column(self):
self.assertEqual(
self.settings_to_cmd_args_env({