mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-06-29 03:30:22 -07:00
Adding the following Test Coverage:
Use mysql_user module to create, delete users. Update user password and ensure new password was updated for the correct user. Assert user has access to multiple databases Assert user creation, deleting using different user privilege and ensure privilege work correctly.
This commit is contained in:
parent
b64a5ff73d
commit
eaf4571e42
11 changed files with 439 additions and 1 deletions
|
@ -209,7 +209,8 @@ def user_mod(cursor, user, host, password, new_priv, append_privs):
|
|||
for db_table in db_table_intersect:
|
||||
priv_diff = set(new_priv[db_table]) ^ set(curr_priv[db_table])
|
||||
if (len(priv_diff) > 0):
|
||||
privileges_revoke(cursor, user,host,db_table,grant_option)
|
||||
if not append_privs:
|
||||
privileges_revoke(cursor, user,host,db_table,grant_option)
|
||||
privileges_grant(cursor, user,host,db_table,new_priv[db_table])
|
||||
changed = True
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue