mirror of
https://github.com/psycopg/psycopg2.git
synced 2024-11-23 01:16:34 +03:00
Test that the empty dsn is a valid make_dsn input
This commit is contained in:
parent
6893295a87
commit
7155d06cdc
|
@ -384,6 +384,10 @@ class MakeDsnTestCase(ConnectingTestCase):
|
||||||
def test_there_has_to_be_something(self):
|
def test_there_has_to_be_something(self):
|
||||||
self.assertRaises(TypeError, ext.make_dsn)
|
self.assertRaises(TypeError, ext.make_dsn)
|
||||||
|
|
||||||
|
def test_empty_string(self):
|
||||||
|
dsn = ext.make_dsn('')
|
||||||
|
self.assertEqual(dsn, '')
|
||||||
|
|
||||||
def test_empty_param(self):
|
def test_empty_param(self):
|
||||||
dsn = ext.make_dsn(database='sony', password='')
|
dsn = ext.make_dsn(database='sony', password='')
|
||||||
self.assertDsnEqual(dsn, "dbname=sony password=''")
|
self.assertDsnEqual(dsn, "dbname=sony password=''")
|
||||||
|
|
Loading…
Reference in New Issue
Block a user