fix sanity tests for python 2.6 in ansible-core 2.12 for good

This commit is contained in:
Laurent Indermuehle 2023-09-19 14:48:10 +02:00
parent 89b42e2b83
commit 4093de51dd
No known key found for this signature in database
GPG key ID: 93FA944C9F34DD09

View file

@ -554,11 +554,11 @@ class MySQL_Info(object):
# indicate an empty string. # indicate an empty string.
# #
# TODO: when dropping support of ansible-core 2.12, change: # TODO: when dropping support of ansible-core 2.12, change:
# set((x for x in priv)) # set([x for x in priv]) == set(['PROXY', 'GRANT'])
# into: # into:
# set(priv) # set(priv) == {'PROXY', 'GRANT'}
# This is because the Sanity test for 2.12 uses Python 2.6!!! # This is because the Sanity test for 2.12 uses Python 2.6!!!
if set((x for x in priv)) == {'PROXY', 'GRANT'} and user == 'root': if set([x for x in priv]) == set(['PROXY', 'GRANT']) and user == 'root':
priv_string.append("'``@`%`: 'PROXY,GRANT'") priv_string.append("'``@`%`: 'PROXY,GRANT'")
continue continue