@@ -57,6 +57,8 @@ cmd_prefix bash -c "chmod 600 ~pulp/.netrc"
57
57
# Generate bindings
58
58
# ##################
59
59
60
+ echo " ::group::Generate bindings"
61
+
60
62
touch bindings_requirements.txt
61
63
pushd ../pulp-openapi-generator
62
64
# Use app_label to generate api.json and package to produce the proper package name.
@@ -79,10 +81,10 @@ pushd ../pulp-openapi-generator
79
81
# there, because we did not merge plugins into pulpcore back then.
80
82
MODULE=" $( jq -r ' .module // (.package|gsub("-"; "_"))' <<< " ${ITEM}" ) "
81
83
PACKAGE=" ${MODULE%% .* } "
84
+ cmd_prefix pulpcore-manager openapi --bindings --component " ${COMPONENT} " > " ${COMPONENT} -api.json"
82
85
if [[ ! " ${BUILT_CLIENTS} " =~ " ${COMPONENT} " ]]
83
86
then
84
87
rm -rf " ./${PACKAGE} -client"
85
- cmd_prefix pulpcore-manager openapi --bindings --component " ${COMPONENT} " > " ${COMPONENT} -api.json"
86
88
./gen-client.sh " ${COMPONENT} -api.json" " ${COMPONENT} " python " ${PACKAGE} "
87
89
pushd " ${PACKAGE} -client"
88
90
python setup.py sdist bdist_wheel --python-tag py3
@@ -100,6 +102,16 @@ pushd ../pulp-openapi-generator
100
102
done
101
103
popd
102
104
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
+
103
115
# Install test requirements
104
116
# ##########################
105
117
140
152
else
141
153
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"
142
154
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
144
156
fi
145
157
pushd ../pulp-cli
146
158
pip install -r test_requirements.txt
0 commit comments