Adds fixes to bigip_asm_policy (#33440)

Integrates some upstream changes that were made and fixes several
spacing and testing errors
This commit is contained in:
Tim Rupp 2017-11-30 15:50:07 -08:00 committed by GitHub
parent 7bd0af15d2
commit 5fa25a0288
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 12193 additions and 4 deletions

View file

@ -556,11 +556,19 @@ class BaseManager(object):
return True
return False
def _file_is_missing(self):
if not os.path.exists(self.want.file):
return True
return False
def create(self):
task = None
if self.want.active is None:
self.want.update(dict(active=False))
if self._file_is_missing():
raise F5ModuleError(
"The specified ASM policy file does not exist"
)
self._set_changed_options()
if self.client.check_mode:
return True