Skip to content

Commit

Permalink
Minor typo fixes
Browse files Browse the repository at this point in the history
Signed-off-by: Abhijeet Kasurde <[email protected]>
  • Loading branch information
Akasurde committed Mar 19, 2024
1 parent 6a9d54b commit d6aeefb
Show file tree
Hide file tree
Showing 9 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion plugins/inventory/now.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ def _compose(self, template, variables):
else:
t.available_variables = variables

""" Only change that we have overriden is that we do not disable lookups"""
""" Only change that we have overridden is that we do not disable lookups"""
return t.template(
"%s%s%s"
% (
Expand Down
2 changes: 1 addition & 1 deletion plugins/module_utils/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def table_name(module):

def resource_name(module):
"""
Return either the api_path or the table name from modules's parameters
Return either the api_path or the table name from modules' parameters
"""
return module.params["resource"] or module.params["api_path"]

Expand Down
2 changes: 1 addition & 1 deletion plugins/module_utils/generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def __init__(self, client, batch_size=1000):
def list_records(self, api_path, query=None):
"""
List records from api_path.
The method is retreiving all the records by making multiple GET requests to server.
The method is retrieving all the records by making multiple GET requests to server.
api_path -- full path (ex: "api/now/cmdb/instance/cmdb_ci_linux_server"
query -- query in SNow format
Expand Down
2 changes: 1 addition & 1 deletion plugins/modules/api_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@
no_count: false
register: result
- name: Retreive all linux servers
- name: Retrieve all linux servers
servicenow.itsm.api_info:
api_path: api/now/cmdb/instance/cmdb_ci_linux_server
"""
Expand Down
4 changes: 2 additions & 2 deletions plugins/modules/configuration_item_info.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,13 +87,13 @@
name: my-configuration-item
register: result
- name: Retrieve all hardare configuration items by using field query
- name: Retrieve all hardware configuration items by using field query
servicenow.itsm.configuration_item_info:
query:
- category: = Hardware
register: result
- name: Retrieve all hardare configuration items by using field sysparm_query
- name: Retrieve all hardware configuration items by using field sysparm_query
servicenow.itsm.configuration_item_info:
sysparm_query: category=Hardware
register: result
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/targets/api/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
SN_PASSWORD: "{{ sn_password }}"

block:
- name: create user (object with encryped fields)
- name: create user (object with encrypted fields)
servicenow.itsm.api:
resource: sys_user
action: post
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@

short_description: "Changed template - {{ short_desc }}"
description: "Desciption is changed also - {{ short_desc }} {{ long_desc }}"
description: "Description is changed also - {{ short_desc }} {{ long_desc }}"
2 changes: 1 addition & 1 deletion tests/integration/targets/api_generic/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
SN_PASSWORD: "{{ sn_password }}"

block:
- name: Retreive all ci linux server cmdb
- name: Retrieve all ci linux server cmdb
servicenow.itsm.api_info:
api_path: "api/now/cmdb/instance/cmdb_ci_linux_server"
register: initial
Expand Down
6 changes: 3 additions & 3 deletions tests/unit/plugins/module_utils/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,11 @@ def test_valid_json(self):
resp = client.Response(
200,
'{"a": ["b", "c"], "d": 1}',
headers=[("Content-type", "applcation/json")],
headers=[("Content-type", "application/json")],
)

assert resp.status == 200
assert resp.headers == {"content-type": "applcation/json"}
assert resp.headers == {"content-type": "application/json"}
assert resp.data == '{"a": ["b", "c"], "d": 1}'
assert resp.json == {"a": ["b", "c"], "d": 1}

Expand All @@ -72,7 +72,7 @@ def test_json_is_cached(self, mocker):
resp = client.Response(
200,
'{"a": ["b", "c"], "d": 1}',
headers=[("Content-type", "applcation/json")],
headers=[("Content-type", "application/json")],
)
resp.json
resp.json
Expand Down

0 comments on commit d6aeefb

Please sign in to comment.