Skip to content

Commit 3c90301

Browse files
Fail tests if resources are not found
1 parent d0aff48 commit 3c90301

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

test/integration/models/iam/iam_test.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def test_get_account_permissions(test_linode_client):
6767
account_permissions = client.iam.account_permissions_get(username)
6868

6969
if not account_permissions:
70-
pytest.skip("No account permissions found for the user.")
70+
pytest.fail("No account permissions found for the user.")
7171
else:
7272
assert len(account_permissions) > 0
7373

@@ -78,15 +78,15 @@ def test_get_entity_permissions(test_linode_client):
7878

7979
entities = client.iam.entities()
8080
if not entities:
81-
pytest.skip("no entities")
81+
pytest.fail("No entities found in IAM response.")
8282
else:
8383
entity = entities[0]
8484
entity_permissions = client.iam.entity_permissions_get(
8585
username, entity.type, entity.id
8686
)
8787
if not entity_permissions:
88-
pytest.skip(
89-
"no entity permissions found for the user and chosen entity."
88+
pytest.fail(
89+
"No entity permissions found for the user and chosen entity."
9090
)
9191
else:
9292
assert len(entity_permissions) > 0

0 commit comments

Comments
 (0)