@@ -57,6 +57,8 @@ cmd_prefix bash -c "chmod 600 ~pulp/.netrc"
5757# Generate bindings
5858# ##################
5959
60+ echo " ::group::Generate bindings"
61+
6062touch bindings_requirements.txt
6163pushd ../pulp-openapi-generator
6264 # Use app_label to generate api.json and package to produce the proper package name.
@@ -79,10 +81,10 @@ pushd ../pulp-openapi-generator
7981 # there, because we did not merge plugins into pulpcore back then.
8082 MODULE=" $( jq -r ' .module // (.package|gsub("-"; "_"))' <<< " ${ITEM}" ) "
8183 PACKAGE=" ${MODULE%% .* } "
84+ cmd_prefix pulpcore-manager openapi --bindings --component " ${COMPONENT} " > " ${COMPONENT} -api.json"
8285 if [[ ! " ${BUILT_CLIENTS} " =~ " ${COMPONENT} " ]]
8386 then
8487 rm -rf " ./${PACKAGE} -client"
85- cmd_prefix pulpcore-manager openapi --bindings --component " ${COMPONENT} " > " ${COMPONENT} -api.json"
8688 ./gen-client.sh " ${COMPONENT} -api.json" " ${COMPONENT} " python " ${PACKAGE} "
8789 pushd " ${PACKAGE} -client"
8890 python setup.py sdist bdist_wheel --python-tag py3
@@ -100,6 +102,16 @@ pushd ../pulp-openapi-generator
100102 done
101103popd
102104
105+ echo " ::endgroup::"
106+
107+ echo " ::group::Debug bindings diffs"
108+
109+ # Bindings diff for python
110+ jq ' (.paths[][].parameters|select(.)) |= sort_by(.name)' < " python-api.json" > " build-api.json"
111+ jq ' (.paths[][].parameters|select(.)) |= sort_by(.name)' < " ../pulp-openapi-generator/python-api.json" > " test-api.json"
112+ jsondiff --indent 2 build-api.json test-api.json || true
113+ echo " ::endgroup::"
114+
103115# Install test requirements
104116# ##########################
105117
140152 else
141153 cmd_user_prefix bash -c " pytest -v -r sx --color=yes --suppress-no-test-exit-code --pyargs pulp_python.tests.functional -m parallel -n 8"
142154 cmd_user_prefix bash -c " pytest -v -r sx --color=yes --suppress-no-test-exit-code --pyargs pulp_python.tests.functional -m 'not parallel'"
143- fi
155+ fi
144156fi
145157pushd ../pulp-cli
146158pip install -r test_requirements.txt
0 commit comments