Skip to content

Commit

Permalink
Some small test refactors
Browse files Browse the repository at this point in the history
  • Loading branch information
zliang-akamai committed Oct 8, 2024
1 parent 601dc54 commit 5c722f5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
7 changes: 3 additions & 4 deletions tests/integration/account/test_account.py
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ def test_user_list():


@pytest.fixture
def get_user_id():
def username():
user_id = (
exec_test_command(
[
Expand All @@ -255,11 +255,10 @@ def get_user_id():
yield first_id


def test_user_view(get_user_id):
user_id = get_user_id
def test_user_view(username: str):
res = (
exec_test_command(
["linode-cli", "users", "view", user_id, "--text", "--delimiter=,"]
["linode-cli", "users", "view", username, "--text", "--delimiter=,"]
)
.stdout.decode()
.rstrip()
Expand Down
4 changes: 1 addition & 3 deletions tests/integration/linodes/test_rebuild.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,13 @@ def test_linode_id(linode_cloud_firewall):

@pytest.mark.flaky(reruns=3, reruns_delay=2)
def test_rebuild_fails_without_image(test_linode_id):
linode_id = test_linode_id

result = exec_failing_test_command(
BASE_CMD
+ [
"rebuild",
"--root_pass",
DEFAULT_RANDOM_PASS,
linode_id,
test_linode_id,
"--text",
"--no-headers",
],
Expand Down

0 comments on commit 5c722f5

Please sign in to comment.