diff --git a/lib/ansible/modules/cloud/digital_ocean/digital_ocean_certificate.py b/lib/ansible/modules/cloud/digital_ocean/digital_ocean_certificate.py index 24721053ec8..de579967a55 100644 --- a/lib/ansible/modules/cloud/digital_ocean/digital_ocean_certificate.py +++ b/lib/ansible/modules/cloud/digital_ocean/digital_ocean_certificate.py @@ -108,7 +108,7 @@ def core(module): if cert['name'] == name: module.fail_json(msg="Certificate name %s already exists" % name) - # Certificate does not exists, let us create it + # Certificate does not exist, let us create it cert_data = dict(name=name, private_key=module.params['private_key'], leaf_certificate=module.params['leaf_certificate']) diff --git a/lib/ansible/modules/cloud/digital_ocean/digital_ocean_tag.py b/lib/ansible/modules/cloud/digital_ocean/digital_ocean_tag.py index 4dcafea6926..9e04e192271 100644 --- a/lib/ansible/modules/cloud/digital_ocean/digital_ocean_tag.py +++ b/lib/ansible/modules/cloud/digital_ocean/digital_ocean_tag.py @@ -60,7 +60,7 @@ EXAMPLES = ''' name: production state: present -- name: tag a resource; creating the tag if it does not exists +- name: tag a resource; creating the tag if it does not exist digital_ocean_tag: name: "{{ item }}" resource_id: "73333005" diff --git a/lib/ansible/modules/cloud/google/gc_storage.py b/lib/ansible/modules/cloud/google/gc_storage.py index d190ca8b7fa..a2700a9d2ac 100644 --- a/lib/ansible/modules/cloud/google/gc_storage.py +++ b/lib/ansible/modules/cloud/google/gc_storage.py @@ -387,7 +387,7 @@ def handle_delete(module, gs, bucket, obj): if key_check(module, gs, bucket, obj): module.exit_json(msg="Object has been deleted.", changed=delete_key(module, gs, bucket, obj)) else: - module.exit_json(msg="Object does not exists.", changed=False) + module.exit_json(msg="Object does not exist.", changed=False) else: module.exit_json(msg="Bucket does not exist.", changed=False) else: diff --git a/lib/ansible/modules/cloud/ovirt/ovirt_storage_domains.py b/lib/ansible/modules/cloud/ovirt/ovirt_storage_domains.py index 67df3a7aa3d..ac5bf08d1a2 100644 --- a/lib/ansible/modules/cloud/ovirt/ovirt_storage_domains.py +++ b/lib/ansible/modules/cloud/ovirt/ovirt_storage_domains.py @@ -439,7 +439,7 @@ class StorageDomainModule(BaseModule): # Get data center object of the storage domain: dcs_service = self._connection.system_service().data_centers_service() - # Search the data_center name, if it does not exists, try to search by guid. + # Search the data_center name, if it does not exist, try to search by guid. dc = search_by_name(dcs_service, dc_name) if dc is None: dc = get_entity(dcs_service.service(dc_name)) diff --git a/lib/ansible/modules/cloud/vmware/vmware_guest.py b/lib/ansible/modules/cloud/vmware/vmware_guest.py index eb633f2c6ba..b68a3e31187 100644 --- a/lib/ansible/modules/cloud/vmware/vmware_guest.py +++ b/lib/ansible/modules/cloud/vmware/vmware_guest.py @@ -986,7 +986,7 @@ class PyVmomiHelper(PyVmomi): " a VLAN name under VM network list.") if 'name' in network and find_obj(self.content, [vim.Network], network['name']) is None: - self.module.fail_json(msg="Network '%(name)s' does not exists" % network) + self.module.fail_json(msg="Network '%(name)s' does not exist." % network) elif 'vlan' in network: dvps = self.cache.get_all_objs(self.content, [vim.dvs.DistributedVirtualPortgroup]) for dvp in dvps: @@ -1333,7 +1333,7 @@ class PyVmomiHelper(PyVmomi): ident.guiRunOnce.commandList = self.params['customization']['runonce'] else: - # FIXME: We have no clue whether this non-Windows OS is actually Linux, hence it might fail ! + # FIXME: We have no clue whether this non-Windows OS is actually Linux, hence it might fail! # For Linux guest OS, use LinuxPrep # https://pubs.vmware.com/vi3/sdk/ReferenceGuide/vim.vm.customization.LinuxPrep.html @@ -1352,7 +1352,7 @@ class PyVmomiHelper(PyVmomi): self.customspec.identity = ident def get_vm_scsi_controller(self, vm_obj): - # If vm_obj doesn't exists no SCSI controller to find + # If vm_obj doesn't exist there is no SCSI controller to find if vm_obj is None: return None diff --git a/lib/ansible/modules/cloud/vmware/vmware_local_role_manager.py b/lib/ansible/modules/cloud/vmware/vmware_local_role_manager.py index 128cd0b3566..86424d22b40 100644 --- a/lib/ansible/modules/cloud/vmware/vmware_local_role_manager.py +++ b/lib/ansible/modules/cloud/vmware/vmware_local_role_manager.py @@ -192,7 +192,7 @@ class VMwareLocalRoleManager(PyVmomi): failIfUsed=self.force) except vim.fault.NotFound as e: self.module.fail_json(msg="Failed to remove a role %s as the user specified role name " - "does not exists." % self.role_name, + "does not exist." % self.role_name, details=e.msg) except vim.fault.RemoveFailed as e: msg = "Failed to remove a role %s as the user specified role name." % self.role_name diff --git a/lib/ansible/modules/cloud/vmware/vmware_vm_vm_drs_rule.py b/lib/ansible/modules/cloud/vmware/vmware_vm_vm_drs_rule.py index 1dae8120046..34c4cf0855d 100644 --- a/lib/ansible/modules/cloud/vmware/vmware_vm_vm_drs_rule.py +++ b/lib/ansible/modules/cloud/vmware/vmware_vm_vm_drs_rule.py @@ -231,7 +231,7 @@ class VmwareDrs(PyVmomi): # Create def create(self): """ - Function to create a DRS rule if rule does not exists + Function to create a DRS rule if rule does not exist """ rule_obj = self.get_rule_key_by_name(rule_name=self.rule_name) if rule_obj is not None: diff --git a/lib/ansible/modules/identity/ipa/ipa_sudocmdgroup.py b/lib/ansible/modules/identity/ipa/ipa_sudocmdgroup.py index 12af2642c5e..f7bc0b9a0ee 100644 --- a/lib/ansible/modules/identity/ipa/ipa_sudocmdgroup.py +++ b/lib/ansible/modules/identity/ipa/ipa_sudocmdgroup.py @@ -51,7 +51,7 @@ EXAMPLES = ''' ipa_user: admin ipa_pass: topsecret -- name: Ensure sudo command group does not exists +- name: Ensure sudo command group does not exist ipa_sudocmdgroup: name: group01 state: absent diff --git a/lib/ansible/modules/monitoring/grafana_dashboard.py b/lib/ansible/modules/monitoring/grafana_dashboard.py index 5fb5add5ab4..e351204693c 100644 --- a/lib/ansible/modules/monitoring/grafana_dashboard.py +++ b/lib/ansible/modules/monitoring/grafana_dashboard.py @@ -242,8 +242,8 @@ def grafana_delete_dashboard(module, data): else: raise GrafanaAPIException('Unable to update the dashboard %s : %s' % (data['slug'], info)) else: - # dashboard does not exists : do nothing - result = {'msg': "Dashboard %s does not exists" % data['slug'], + # dashboard does not exist, do nothing + result = {'msg': "Dashboard %s does not exist." % data['slug'], 'changed': False, 'slug': data['slug']} @@ -274,7 +274,7 @@ def grafana_export_dashboard(module, data): 'slug': data['slug'], 'changed': True} else: - result = {'msg': "Dashboard %s does not exists" % data['slug'], + result = {'msg': "Dashboard %s does not exist." % data['slug'], 'slug': data['slug'], 'changed': False} diff --git a/lib/ansible/modules/monitoring/grafana_datasource.py b/lib/ansible/modules/monitoring/grafana_datasource.py index 98e4ccf23a1..3e8acde8576 100644 --- a/lib/ansible/modules/monitoring/grafana_datasource.py +++ b/lib/ansible/modules/monitoring/grafana_datasource.py @@ -429,8 +429,8 @@ def grafana_delete_datasource(module, data): else: raise GrafanaAPIException('Unable to update the datasource id %s : %s' % (ds['id'], info)) else: - # datasource does not exists : do nothing - result = {'msg': "Datasource %s does not exists" % data['name'], + # datasource does not exist, do nothing + result = {'msg': "Datasource %s does not exist." % data['name'], 'changed': False, 'id': 0, 'name': data['name']} diff --git a/lib/ansible/modules/network/cloudengine/ce_interface.py b/lib/ansible/modules/network/cloudengine/ce_interface.py index 0e11df4b2c3..8e5fdc54f24 100644 --- a/lib/ansible/modules/network/cloudengine/ce_interface.py +++ b/lib/ansible/modules/network/cloudengine/ce_interface.py @@ -809,15 +809,15 @@ class Interface(object): # delete interface self.delete_interface(self.interface) else: - # interface does not exists + # interface does not exist self.module.fail_json( - msg='Error: interface does not exists.') + msg='Error: interface does not exist.') else: # default if not self.intf_info: - # error, interface does not exists + # error, interface does not exist self.module.fail_json( - msg='Error: interface does not exists.') + msg='Error: interface does not exist.') else: self.default_interface(self.interface) diff --git a/lib/ansible/modules/network/cloudengine/ce_mtu.py b/lib/ansible/modules/network/cloudengine/ce_mtu.py index 9b695bf52f2..f32677de973 100644 --- a/lib/ansible/modules/network/cloudengine/ce_mtu.py +++ b/lib/ansible/modules/network/cloudengine/ce_mtu.py @@ -472,7 +472,7 @@ class Mtu(object): # get interface info self.intf_info = self.get_interface_dict(self.interface) if not self.intf_info: - self.module.fail_json(msg='Error: interface does not exists.') + self.module.fail_json(msg='Error: interface does not exist.') # check interface if self.mtu and self.intf_info['isL2SwitchPort'] == 'true': diff --git a/lib/ansible/modules/network/cloudengine/ce_switchport.py b/lib/ansible/modules/network/cloudengine/ce_switchport.py index aa9176b3935..865a50c5d88 100644 --- a/lib/ansible/modules/network/cloudengine/ce_switchport.py +++ b/lib/ansible/modules/network/cloudengine/ce_switchport.py @@ -719,7 +719,7 @@ class SwitchPort(object): # get interface info self.intf_info = self.get_interface_dict(self.interface) if not self.intf_info: - self.module.fail_json(msg='Error: Interface does not exists.') + self.module.fail_json(msg='Error: Interface does not exist.') if not self.is_l2switchport(): self.module.fail_json( @@ -764,7 +764,7 @@ class SwitchPort(object): self.check_params() if not self.intf_info: - self.module.fail_json(msg='Error: interface does not exists.') + self.module.fail_json(msg='Error: interface does not exist.') self.get_existing() self.get_proposed() diff --git a/lib/ansible/modules/source_control/gitlab_group.py b/lib/ansible/modules/source_control/gitlab_group.py index af6a30ab701..c59fdc7f187 100644 --- a/lib/ansible/modules/source_control/gitlab_group.py +++ b/lib/ansible/modules/source_control/gitlab_group.py @@ -16,7 +16,7 @@ DOCUMENTATION = ''' module: gitlab_group short_description: Creates/updates/deletes Gitlab Groups description: - - When the group does not exists in Gitlab, it will be created. + - When the group does not exist in Gitlab, it will be created. - When the group does exists and state=absent, the group will be deleted. version_added: "2.1" author: "Werner Dijkerman (@dj-wasabi)" @@ -209,7 +209,7 @@ def main(): module.exit_json(changed=True, result="Successfully deleted group %s" % group_name) else: if state == "absent": - module.exit_json(changed=False, result="Group deleted or does not exists") + module.exit_json(changed=False, result="Group deleted or does not exist") else: if group_exists: module.exit_json(changed=False) diff --git a/lib/ansible/modules/source_control/gitlab_project.py b/lib/ansible/modules/source_control/gitlab_project.py index 8933924d846..c50e4400d5d 100644 --- a/lib/ansible/modules/source_control/gitlab_project.py +++ b/lib/ansible/modules/source_control/gitlab_project.py @@ -16,7 +16,7 @@ DOCUMENTATION = ''' module: gitlab_project short_description: Creates/updates/deletes Gitlab Projects description: - - When the project does not exists in Gitlab, it will be created. + - When the project does not exist in Gitlab, it will be created. - When the project does exists and state=absent, the project will be deleted. - When changes are made to the project, the project will be updated. version_added: "2.1" @@ -397,7 +397,7 @@ def main(): module.exit_json(changed=True, result="Successfully deleted project %s" % project_name) else: if state == "absent": - module.exit_json(changed=False, result="Project deleted or does not exists") + module.exit_json(changed=False, result="Project deleted or does not exist") else: if project.createOrUpdateProject(project_exists, group_name, import_url, arguments): module.exit_json(changed=True, result="Successfully created or updated the project %s" % project_name) diff --git a/lib/ansible/modules/source_control/gitlab_user.py b/lib/ansible/modules/source_control/gitlab_user.py index aac1d5586d8..52c18f94e2b 100644 --- a/lib/ansible/modules/source_control/gitlab_user.py +++ b/lib/ansible/modules/source_control/gitlab_user.py @@ -16,7 +16,7 @@ DOCUMENTATION = ''' module: gitlab_user short_description: Creates/updates/deletes Gitlab Users description: - - When the user does not exists in Gitlab, it will be created. + - When the user does not exist in Gitlab, it will be created. - When the user does exists and state=absent, the user will be deleted. - When changes are made to user, the user will be updated. version_added: "2.1" @@ -352,7 +352,7 @@ def main(): # Check if user exists, if not exists and state = absent, we exit nicely. if not user.existsUser(user_username) and state == "absent": - module.exit_json(changed=False, result="User already deleted or does not exists") + module.exit_json(changed=False, result="User already deleted or does not exist") else: # User exists, if state == "absent": diff --git a/lib/ansible/modules/system/osx_defaults.py b/lib/ansible/modules/system/osx_defaults.py index 74f0361a9a9..f5eedd41f4c 100644 --- a/lib/ansible/modules/system/osx_defaults.py +++ b/lib/ansible/modules/system/osx_defaults.py @@ -236,7 +236,7 @@ class OSXDefaults(object): # First try to find out the type rc, out, err = self.module.run_command(self._base_command() + ["read-type", self.domain, self.key]) - # If RC is 1, the key does not exists + # If RC is 1, the key does not exist if rc == 1: return None diff --git a/lib/ansible/modules/web_infrastructure/ejabberd_user.py b/lib/ansible/modules/web_infrastructure/ejabberd_user.py index 3c1ea02f9cd..f7c804cf0aa 100644 --- a/lib/ansible/modules/web_infrastructure/ejabberd_user.py +++ b/lib/ansible/modules/web_infrastructure/ejabberd_user.py @@ -56,7 +56,7 @@ notes: EXAMPLES = ''' # Example playbook entries using the ejabberd_user module to manage users state. -- name: create a user if it does not exists +- name: create a user if it does not exist ejabberd_user: username: test host: server diff --git a/test/integration/targets/ecs_ecr/tasks/main.yml b/test/integration/targets/ecs_ecr/tasks/main.yml index 6e95f406838..e223752242d 100644 --- a/test/integration/targets/ecs_ecr/tasks/main.yml +++ b/test/integration/targets/ecs_ecr/tasks/main.yml @@ -88,7 +88,7 @@ - result is not changed - - name: When in check mode, and deleting a policy that does not exists + - name: When in check mode, and deleting a policy that does not exist ecs_ecr: region: '{{ ec2_region }}' name: '{{ ecr_name }}' diff --git a/test/integration/targets/vmware_guest/tasks/network_negative_test.yml b/test/integration/targets/vmware_guest/tasks/network_negative_test.yml index f490d2bed86..aa2be2aa4db 100644 --- a/test/integration/targets/vmware_guest/tasks/network_negative_test.yml +++ b/test/integration/targets/vmware_guest/tasks/network_negative_test.yml @@ -65,7 +65,7 @@ assert: that: - "not non_existent_network.changed" - - "\"Network 'Non existent VM' does not exists\" in non_existent_network.msg" + - "\"Network 'Non existent VM' does not exist\" in non_existent_network.msg" - name: create new VMs with network and with only IP vmware_guest: diff --git a/test/integration/targets/win_dsc/tasks/destructive.yml b/test/integration/targets/win_dsc/tasks/destructive.yml index 96166088398..86051fe3949 100644 --- a/test/integration/targets/win_dsc/tasks/destructive.yml +++ b/test/integration/targets/win_dsc/tasks/destructive.yml @@ -13,7 +13,7 @@ name: xWebAdministration state: present -- name: ensure IIS website does not exists +- name: ensure IIS website does not exist win_iis_website: name: Ansible DSC Test state: absent