diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_binding.py b/lib/ansible/modules/extras/messaging/rabbitmq_binding.py index bc466388acc..2d0f9e4f089 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_binding.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_binding.py @@ -224,4 +224,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_exchange.py b/lib/ansible/modules/extras/messaging/rabbitmq_exchange.py index 74758457270..011b63facc7 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_exchange.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_exchange.py @@ -202,4 +202,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_parameter.py b/lib/ansible/modules/extras/messaging/rabbitmq_parameter.py index 602f92fc4c4..f3d188fd25a 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_parameter.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_parameter.py @@ -157,4 +157,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_plugin.py b/lib/ansible/modules/extras/messaging/rabbitmq_plugin.py index 6aa4fac3053..832af02faf8 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_plugin.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_plugin.py @@ -149,4 +149,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_policy.py b/lib/ansible/modules/extras/messaging/rabbitmq_policy.py index 8293f6f8972..ef7ffc60686 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_policy.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_policy.py @@ -171,4 +171,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_queue.py b/lib/ansible/modules/extras/messaging/rabbitmq_queue.py index ec9e782f40d..68d869da67f 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_queue.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_queue.py @@ -240,4 +240,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_user.py b/lib/ansible/modules/extras/messaging/rabbitmq_user.py index 470ae7c1431..c51c6b0b592 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_user.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_user.py @@ -305,4 +305,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main() diff --git a/lib/ansible/modules/extras/messaging/rabbitmq_vhost.py b/lib/ansible/modules/extras/messaging/rabbitmq_vhost.py index 1ffb3d2674f..ad8f9cba207 100644 --- a/lib/ansible/modules/extras/messaging/rabbitmq_vhost.py +++ b/lib/ansible/modules/extras/messaging/rabbitmq_vhost.py @@ -146,4 +146,6 @@ def main(): # import module snippets from ansible.module_utils.basic import * -main() + +if __name__ == '__main__': + main()