Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
No-Issue
  • Loading branch information
chr-stian committed Feb 9, 2024
1 parent e18e7d3 commit c0d0b84
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
1 change: 0 additions & 1 deletion galaxy_ng/tests/integration/api/test_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ def test_gateway_auth_admin_gateway_sessionid(galaxy_client):

@pytest.mark.deployment_standalone
@pytest.mark.galaxyapi_smoke
@pytest.mark.skip
@pytest.mark.skipif(not aap_gateway(), reason="This test only runs if AAP Gateway is deployed")
def test_gateway_auth_admin_gateway_csrftoken(galaxy_client):
"""Test whether admin can not access collections page using invalid csrftoken."""
Expand Down
18 changes: 10 additions & 8 deletions galaxy_ng/tests/integration/cli/test_cli_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

@pytest.mark.cli
@pytest.mark.all
def test_publish_newer_version_collection(ansible_config, cleanup_collections, uncertifiedv2):
def test_publish_newer_version_collection(galaxy_client, cleanup_collections, uncertifiedv2):
"""Test whether a newer version of collection can be installed after being published.
If the collection version was not certified the version to be installed
Expand All @@ -24,11 +24,12 @@ def test_publish_newer_version_collection(ansible_config, cleanup_collections, u
# FIXME - ^^^ is that really possible?
v1 = uncertifiedv2[0]
v2 = uncertifiedv2[1]

gc = galaxy_client("basic_user")
# Install collection without version ...
install_pid = ansible_galaxy(
f"collection install {v1.namespace}.{v1.name}",
ansible_config=ansible_config("basic_user"),
# ansible_config=ansible_config("basic_user"),
galaxy_client=gc,
cleanup=False,
check_retcode=False
)
Expand All @@ -47,7 +48,7 @@ def test_publish_newer_version_collection(ansible_config, cleanup_collections, u
"work with signatures required "
"on move.")
def test_publish_newer_certified_collection_version(
ansible_config,
galaxy_client,
cleanup_collections,
certifiedv2,
settings
Expand All @@ -59,11 +60,12 @@ def test_publish_newer_certified_collection_version(

v1 = certifiedv2[0]
v2 = certifiedv2[1]

gc = galaxy_client("basic_user")
# Ensure v2 gets installed by default ...
ansible_galaxy(
f"collection install {v1.namespace}.{v1.name}",
ansible_config=ansible_config("basic_user")
# ansible_config=ansible_config("basic_user")
galaxy_client=gc
)
collection_path = get_collection_full_path(v1.namespace, v1.name)
ci = CollectionInspector(directory=collection_path)
Expand Down Expand Up @@ -94,14 +96,14 @@ def test_publish_same_collection_version(ansible_config, galaxy_client):

@pytest.mark.all
@pytest.mark.cli
def test_publish_and_install_by_self(ansible_config, published, cleanup_collections):
def test_publish_and_install_by_self(galaxy_client, published, cleanup_collections):
"""A publishing user has the permission to install an uncertified version of their
own collection.
"""

ansible_galaxy(
f"collection install {published.namespace}.{published.name}:{published.version}",
ansible_config=ansible_config("basic_user"),
galaxy_client=galaxy_client("basic_user"),
)


Expand Down

0 comments on commit c0d0b84

Please sign in to comment.