@@ -236,10 +236,110 @@ jobs:
236236 with :
237237 language : python
238238
239+ sonarcloud :
240+ name : " quality: sonarcloud"
241+ runs-on : ubuntu-latest
242+ needs : docs-only
243+ steps :
244+ - name : Docs-only short-circuit
245+ if : needs.docs-only.outputs.docs-only == 'true'
246+ run : echo "Docs-only changes detected; skipping SonarCloud."
247+
248+ - name : Checkout code
249+ if : needs.docs-only.outputs.docs-only != 'true'
250+ uses : actions/checkout@v6
251+ with :
252+ fetch-depth : 0
253+
254+ - name : Set up Python
255+ if : needs.docs-only.outputs.docs-only != 'true'
256+ uses : wphillipmoore/standard-actions/actions/python/setup@develop
257+ with :
258+ python-version : " 3.14"
259+
260+ - name : Install dependencies
261+ if : needs.docs-only.outputs.docs-only != 'true'
262+ run : uv sync --frozen --group dev
263+
264+ - name : Run tests with coverage
265+ if : needs.docs-only.outputs.docs-only != 'true'
266+ run : |
267+ uv run pytest \
268+ --cov=pymqrest \
269+ --cov-report=xml \
270+ --cov-branch
271+
272+ - name : Run SonarCloud scan
273+ if : needs.docs-only.outputs.docs-only != 'true'
274+ uses : wphillipmoore/standard-actions/actions/quality/sonarcloud@develop
275+ with :
276+ sonar-token : ${{ secrets.SONAR_TOKEN }}
277+ organization : wphillipmoore
278+ project-key : wphillipmoore_mq-rest-admin-python
279+ sources : " src"
280+ tests : " tests"
281+ coverage-report : " coverage.xml"
282+
283+ codeclimate :
284+ name : " quality: codeclimate"
285+ runs-on : ubuntu-latest
286+ needs : docs-only
287+ permissions :
288+ contents : read
289+ id-token : write
290+ steps :
291+ - name : Docs-only short-circuit
292+ if : needs.docs-only.outputs.docs-only == 'true'
293+ run : echo "Docs-only changes detected; skipping Code Climate."
294+
295+ - name : Checkout code
296+ if : needs.docs-only.outputs.docs-only != 'true'
297+ uses : actions/checkout@v6
298+
299+ - name : Set up Python
300+ if : needs.docs-only.outputs.docs-only != 'true'
301+ uses : wphillipmoore/standard-actions/actions/python/setup@develop
302+ with :
303+ python-version : " 3.14"
304+
305+ - name : Install dependencies
306+ if : needs.docs-only.outputs.docs-only != 'true'
307+ run : uv sync --frozen --group dev
308+
309+ - name : Run tests with coverage
310+ if : needs.docs-only.outputs.docs-only != 'true'
311+ run : |
312+ uv run pytest \
313+ --cov=pymqrest \
314+ --cov-report=lcov \
315+ --cov-branch
316+
317+ - name : Upload coverage to Qlty Cloud
318+ if : needs.docs-only.outputs.docs-only != 'true'
319+ uses : wphillipmoore/standard-actions/actions/quality/codeclimate@develop
320+ with :
321+ files : " coverage.lcov"
322+
239323 integration-tests :
240- name : " test: integration"
324+ name : " test: integration (${{ matrix.python-version }}) "
241325 runs-on : ubuntu-latest
242326 needs : docs-only
327+ strategy :
328+ matrix :
329+ include :
330+ - python-version : " 3.12"
331+ project-suffix : " 3-12"
332+ qm1-rest-port : " 9447"
333+ qm2-rest-port : " 9448"
334+ - python-version : " 3.13"
335+ project-suffix : " 3-13"
336+ qm1-rest-port : " 9449"
337+ qm2-rest-port : " 9450"
338+ - python-version : " 3.14"
339+ project-suffix : " 3-14"
340+ qm1-rest-port : " 9451"
341+ qm2-rest-port : " 9452"
342+
243343 steps :
244344 - name : Docs-only short-circuit
245345 if : needs.docs-only.outputs.docs-only == 'true'
@@ -253,7 +353,7 @@ jobs:
253353 if : needs.docs-only.outputs.docs-only != 'true'
254354 uses : wphillipmoore/standard-actions/actions/python/setup@develop
255355 with :
256- python-version : " 3.14 "
356+ python-version : ${{ matrix.python-version }}
257357
258358 - name : Install dependencies
259359 if : needs.docs-only.outputs.docs-only != 'true'
@@ -263,10 +363,15 @@ jobs:
263363 if : needs.docs-only.outputs.docs-only != 'true'
264364 uses : wphillipmoore/mq-rest-admin-dev-environment/.github/actions/setup-mq@main
265365 with :
266- project-name : pymqrest
366+ project-name : pymqrest-${{ matrix.project-suffix }}
367+ qm1-rest-port : ${{ matrix.qm1-rest-port }}
368+ qm2-rest-port : ${{ matrix.qm2-rest-port }}
267369
268370 - name : Run integration tests
269371 if : needs.docs-only.outputs.docs-only != 'true'
372+ env :
373+ MQ_REST_BASE_URL : https://localhost:${{ matrix.qm1-rest-port }}/ibmmq/rest/v2
374+ MQ_REST_BASE_URL_QM2 : https://localhost:${{ matrix.qm2-rest-port }}/ibmmq/rest/v2
270375 run : |
271376 MQ_SKIP_LIFECYCLE=1 \
272377 PYMQREST_RUN_INTEGRATION=1 \
0 commit comments