-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: alexstroke <111361420+astrokov7@users.noreply.github.com>
- Loading branch information
1 parent
495d3f4
commit 81ba9ad
Showing
7 changed files
with
89 additions
and
39 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import allure | ||
import time | ||
import pytest | ||
|
||
from tests import client | ||
|
||
@pytest.fixture(scope="function", autouse=True) | ||
def story_account_register_account(): | ||
allure.dynamic.story("Account queries accounts") | ||
allure.dynamic.label("permission", "no_permission_required") | ||
|
||
@allure.label("sdk_test_id", "query_all_accounts") | ||
def test_query_all_accounts(): | ||
with allure.step('WHEN client queries all accounts'): | ||
all_accounts = client.query_all_accounts() | ||
with allure.step('THEN there should be some accounts present'): | ||
assert len(all_accounts) > 0, "No accounts found in the system" | ||
|
||
|
||
@allure.label("sdk_test_id", "query_all_accounts_in_domain") | ||
def test_query_all_accounts_in_domain( | ||
GIVEN_registered_domain_with_registered_accounts): | ||
with allure.step( | ||
f'WHEN client queries all accounts in domain "{GIVEN_registered_domain_with_registered_accounts}"'): | ||
time.sleep(3) | ||
accounts_in_domain = client.query_all_accounts_in_domain(GIVEN_registered_domain_with_registered_accounts) | ||
with allure.step( | ||
f'THEN the response should be a non-empty list of accounts in domain "{GIVEN_registered_domain_with_registered_accounts}"'): | ||
assert isinstance(accounts_in_domain, list) and accounts_in_domain, \ | ||
f"Expected a non-empty list of accounts in the domain {GIVEN_registered_domain_with_registered_accounts}, got {accounts_in_domain}" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import allure | ||
import time | ||
import pytest | ||
|
||
from tests import client | ||
|
||
@pytest.fixture(scope="function", autouse=True) | ||
def story_account_register_account(): | ||
allure.dynamic.story("Account queries assets") | ||
allure.dynamic.label("permission", "no_permission_required") | ||
|
||
@pytest.mark.xfail(reason="TO DO") | ||
@allure.label("sdk_test_id", "query_all_assets_owned_by_account") | ||
def test_query_all_assets_owned_by_account( | ||
GIVEN_registered_account_with_assets): | ||
with allure.step( | ||
f'WHEN client queries all assets owned by account "{GIVEN_registered_account_with_assets}"'): | ||
time.sleep(3) | ||
assets_owned_by_account = client.query_all_assets_owned_by_account(GIVEN_registered_account_with_assets) | ||
with allure.step( | ||
f'THEN the response should be a non-empty list of assets owned by account "{GIVEN_registered_account_with_assets}"'): | ||
assert isinstance(assets_owned_by_account, list) and assets_owned_by_account, \ | ||
f"Expected a non-empty list of assets owned by account {GIVEN_registered_account_with_assets}, got {assets_owned_by_account}" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters