Skip to content

Commit

Permalink
skip verify data if upgrade from aap22 hub45
Browse files Browse the repository at this point in the history
No-Issue
  • Loading branch information
chr-stian committed Dec 18, 2023
1 parent ea608dd commit f683a00
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
8 changes: 5 additions & 3 deletions galaxy_ng/tests/integration/api/test_verify_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

from galaxy_ng.tests.integration.conftest import is_hub_4_7_or_higher
from galaxy_ng.tests.integration.utils.iqe_utils import is_upgrade_from_aap23_hub46, \
galaxy_auto_sign_collections
galaxy_auto_sign_collections, is_upgrade_from_aap22_hub45
from galaxy_ng.tests.integration.utils.repo_management_utils import search_collection_endpoint
from galaxykit.collections import collection_info
from galaxykit.groups import get_group_id
Expand All @@ -16,9 +16,11 @@

logger = logging.getLogger(__name__)

SKIP_MESSAGE = "Load data stage was run on AAP 2.3, without repository management"
SKIP_MESSAGE_23 = "Load data stage was run on AAP 2.3, without repository management"
SKIP_MESSAGE_22 = "Load data stage was skipped. No data to verify now."


@pytest.mark.skipif(is_upgrade_from_aap22_hub45(), reason=SKIP_MESSAGE_22)
class TestVerifyData:

@pytest.mark.min_hub_version("4.6dev")
Expand Down Expand Up @@ -96,7 +98,7 @@ def test_verify_data_groups(self, galaxy_client, data):
get_group_id(gc, expected_group["name"])

@pytest.mark.min_hub_version("4.7dev")
@pytest.mark.skipif(is_upgrade_from_aap23_hub46(), reason=SKIP_MESSAGE)
@pytest.mark.skipif(is_upgrade_from_aap23_hub46(), reason=SKIP_MESSAGE_23)
@pytest.mark.verify_data
def test_verify_data_repos(self, galaxy_client, data):
"""
Expand Down
5 changes: 5 additions & 0 deletions galaxy_ng/tests/integration/utils/iqe_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,11 @@ def is_upgrade_from_aap23_hub46():
return upgrade in ('true', 'True', 1, '1', True)


def is_upgrade_from_aap22_hub45():
upgrade = os.getenv("UPGRADE_FROM_AAP22_HUB45", False)
return upgrade in ('true', 'True', 1, '1', True)


def pull_and_tag_test_image(container_engine, registry, tag=None):
image = "alpine"
tag = "alpine:latest" if tag is None else tag
Expand Down

0 comments on commit f683a00

Please sign in to comment.