Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

Commit

Permalink
Enabling CLI test
Browse files Browse the repository at this point in the history
Required PR: pulp/pulp-cli#142

[noissue]
  • Loading branch information
David Davis committed Feb 17, 2021
1 parent 2eaf2ce commit d1d6e5a
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 1 deletion.
17 changes: 17 additions & 0 deletions .github/workflows/scripts/before_install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ then
export PULPCORE_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulpcore\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_SMASH_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp-smash\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_OPENAPI_GENERATOR_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp-openapi-generator\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_CLI_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp-cli\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_FILE_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp_file\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_CONTAINER_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp_container\/pull\/(\d+)' | awk -F'/' '{print $7}')
export PULP_RPM_PR_NUMBER=$(echo $COMMIT_MSG | grep -oP 'Required\ PR:\ https\:\/\/github\.com\/pulp\/pulp_rpm\/pull\/(\d+)' | awk -F'/' '{print $7}')
Expand All @@ -66,6 +67,7 @@ else
export PULPCORE_PR_NUMBER=
export PULP_SMASH_PR_NUMBER=
export PULP_OPENAPI_GENERATOR_PR_NUMBER=
export PULP_CLI_PR_NUMBER=
export PULP_FILE_PR_NUMBER=
export PULP_CONTAINER_PR_NUMBER=
export PULP_RPM_PR_NUMBER=
Expand All @@ -88,6 +90,21 @@ sed -i -e 's/localhost:24817/pulp/g' generate.sh
sed -i -e 's/:24817/pulp/g' generate.sh
cd ..


git clone --depth=1 https://github.com/pulp/pulp-cli.git
if [ -n "$PULP_CLI_PR_NUMBER" ]; then
cd pulp-cli
git fetch origin pull/$PULP_CLI_PR_NUMBER/head:$PULP_CLI_PR_NUMBER
git checkout $PULP_CLI_PR_NUMBER
cd ..
fi

cd pulp-cli
pip install -e .
pulp config create --base-url http://pulp --location tests/settings.toml
cd ..


git clone --depth=1 https://github.com/pulp/pulpcore.git --branch master

cd pulpcore
Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/scripts/script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ if [[ "$TEST" = "docs" || "$TEST" = "publish" ]]; then
echo "Validating OpenAPI schema..."
cat $PWD/.ci/scripts/schema.py | cmd_stdin_prefix bash -c "cat > /tmp/schema.py"
cmd_prefix bash -c "python3 /tmp/schema.py"
# cmd_prefix bash -c "pulpcore-manager spectacular --file pulp_schema.yml --validate"
cmd_prefix bash -c "pulpcore-manager spectacular --file pulp_schema.yml --validate"

if [ -f $POST_DOCS_TEST ]; then
source $POST_DOCS_TEST
Expand Down Expand Up @@ -117,6 +117,9 @@ if [ -f $FUNC_TEST_SCRIPT ]; then
else
pytest -v -r sx --color=yes --pyargs pulp_2to3_migration.tests.functional
fi
pushd ../pulp-cli
pytest -v -m pulp_2to3_migration
popd

if [ -f $POST_SCRIPT ]; then
source $POST_SCRIPT
Expand Down
1 change: 1 addition & 0 deletions template_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ pydocstyle: false
pypi_username: pulp
redmine_project: migration
test_bindings: false
test_cli: true
test_performance: false
test_released_plugin_with_next_pulpcore_release: false
test_s3: false
Expand Down

0 comments on commit d1d6e5a

Please sign in to comment.