mirror of
https://github.com/django/django.git
synced 2025-07-24 13:44:32 +00:00
Fixed #31491 -- Allowed 'password' option in DATABASES['OPTIONS'] on MySQL.
This commit is contained in:
parent
2928019e0c
commit
9e8edc1e55
2 changed files with 22 additions and 3 deletions
|
@ -43,6 +43,22 @@ class MySqlDbshellCommandTestCase(SimpleTestCase):
|
|||
},
|
||||
}))
|
||||
|
||||
def test_options_password(self):
|
||||
self.assertEqual(
|
||||
[
|
||||
'mysql', '--user=someuser', '--password=optionpassword',
|
||||
'--host=somehost', '--port=444', 'somedbname',
|
||||
],
|
||||
self.get_command_line_arguments({
|
||||
'NAME': 'somedbname',
|
||||
'USER': 'someuser',
|
||||
'PASSWORD': 'settingpassword',
|
||||
'HOST': 'somehost',
|
||||
'PORT': 444,
|
||||
'OPTIONS': {'password': 'optionpassword'},
|
||||
}),
|
||||
)
|
||||
|
||||
def test_can_connect_using_sockets(self):
|
||||
self.assertEqual(
|
||||
['mysql', '--user=someuser', '--password=somepassword',
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue