mirror of
https://github.com/ansible-collections/community.mysql.git
synced 2025-04-18 16:31:26 -07:00
Fix user plugin changes in check mode (#596)
* Fix user plugin changes in check mode * Add auth plugin tests * Undo local changes * Improve task names * Fix query * Changes * Add check * Add check * Add check * Add one more check * Add one more check * Fix typo * Change parameter * Testing * Remove tests * Add tests * Test first stteps * Readd tests * Test without check mode * Test with check mode * Test with check mode * Testing * Testing * Add missing tests * Changes for ansible-lint complaints * Fix condition * Update changelogs/fragments/596-fix-check-changes.yaml Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru> * refactor * Add more tests * Fix newpass var * Remove extra test --------- Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
This commit is contained in:
parent
87be61ccf3
commit
0de9685cf1
4 changed files with 175 additions and 68 deletions
|
@ -411,7 +411,8 @@ def user_mod(cursor, user, host, host_all, password, encrypted,
|
|||
else:
|
||||
query_with_args = "ALTER USER %s@%s IDENTIFIED WITH %s", (user, host, plugin)
|
||||
|
||||
cursor.execute(*query_with_args)
|
||||
if not module.check_mode:
|
||||
cursor.execute(*query_with_args)
|
||||
password_changed = True
|
||||
changed = True
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue