[Gitlab] Added verbosity to files #1155
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
detect-changes: | |
uses: ./.github/workflows/detect-changes-matrix.yml | |
test: | |
name: ${{ matrix.folder == '.' && '🌊 Ocean Core' || format('🚢 {0}', matrix.folder) }} | |
needs: detect-changes | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
folder: ${{ fromJson(needs.detect-changes.outputs.matrix) }} | |
steps: | |
- name: Checkout Repo | |
uses: actions/checkout@v4 | |
- name: Install poetry | |
run: pipx install poetry | |
- name: Set up Python 3.11 | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.11' | |
cache: 'poetry' | |
- name: Install dependencies | |
working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
run: | | |
make install | |
# # Core only actions | |
# - name: Build core for smoke test | |
# if: ${{ matrix.folder == '.' }} | |
# working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
# run: | | |
# make build | |
# - name: Run fake integration for core test | |
# working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
# if: ${{ matrix.folder == '.' }} | |
# env: | |
# PORT_CLIENT_ID: ${{ secrets.PORT_CLIENT_ID }} | |
# PORT_CLIENT_SECRET: ${{ secrets.PORT_CLIENT_SECRET }} | |
# PORT_BASE_URL: ${{ secrets.PORT_BASE_URL }} | |
# SMOKE_TEST_SUFFIX: ${{ github.run_id }} | |
# run: | | |
# ./scripts/run-smoke-test.sh | |
# - name: Test Core | |
# if: ${{ matrix.folder == '.' }} | |
# working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
# env: | |
# PYTEST_ADDOPTS: --junitxml=junit/test-results-${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || 'ocean/core' }}.xml | |
# PORT_CLIENT_ID: ${{ secrets.PORT_CLIENT_ID }} | |
# PORT_CLIENT_SECRET: ${{ secrets.PORT_CLIENT_SECRET }} | |
# PORT_BASE_URL: ${{ secrets.PORT_BASE_URL }} | |
# SMOKE_TEST_SUFFIX: ${{ github.run_id }} | |
# run: | | |
# make test | |
- name: Install current core for all integrations | |
working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
if: ${{ matrix.folder == '.' }} | |
run: | | |
echo "Installing local core for all integrations" | |
SCRIPT_TO_RUN='make install/local-core' make execute/all | |
- name: Test all integrations with current core | |
working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
if: ${{ matrix.folder == '.' }} | |
run: | | |
echo "Testing all integrations with local core" | |
SCRIPT_TO_RUN="PYTEST_ADDOPTS=--junitxml=${PWD}/junit/test-results-core-change/\`pwd | xargs basename\`.xml make test" make execute/all | |
# Integration step | |
- name: Test | |
# if: ${{ matrix.folder != '.' }} | |
working-directory: ${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || '.' }} | |
env: | |
PYTEST_ADDOPTS: --junitxml=junit/test-results-${{ matrix.folder != '.' && format('integrations/{0}', matrix.folder) || 'ocean/core' }}.xml | |
run: | | |
make test | |
# Generic | |
- name: Publish Test Report | |
uses: mikepenz/action-junit-report@v4 | |
if: ${{ always() }} | |
with: | |
report_paths: '**/junit/test-results-**/*.xml' | |
include_passed: true | |
require_tests: true | |
fail_on_failure: true |