Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix host owner checking and test name typo #15143

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions tests/foreman/api/test_host.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ def test_positive_update_owner_type(
host.owner = owners[owner_type]
host = host.update(['owner_type', 'owner'])
assert host.owner_type == owner_type
assert host.owner.read() == owners[owner_type]
assert module_target_sat.api.User(id=host.owner.id).read() == owners[owner_type]


@pytest.mark.tier1
Expand Down Expand Up @@ -468,13 +468,13 @@ def test_positive_create_and_update_with_user(
host = module_target_sat.api.Host(
owner=module_user, owner_type='User', organization=module_org, location=module_location
).create()
assert host.owner.read() == module_user
assert module_target_sat.api.User(id=host.owner.id).read() == module_user
new_user = module_target_sat.api.User(
organization=[module_org], location=[module_location]
).create()
host.owner = new_user
host = host.update(['owner'])
assert host.owner.read() == new_user
assert module_target_sat.api.User(id=host.owner.id).read() == new_user


@pytest.mark.tier2
Expand Down
2 changes: 1 addition & 1 deletion tests/foreman/cli/test_user.py
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ def test_positive_create_with_default_loc(self, target_sat):
assert location['name'] == user['default-location']

@pytest.mark.tier1
def test_positive_create_with_defaut_org(self, module_target_sat):
def test_positive_create_with_default_org(self, module_target_sat):
"""Check if user with default organization can be created

:id: cc692b6f-2519-429b-8ecb-c4bb51ed3544
Expand Down