fix: specify inputs types #2
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 package | |
on: | |
workflow_call: | |
inputs: | |
branch_name: | |
description: 'Branch name' | |
type: string | |
required: false | |
python_version: | |
description: 'Python version' | |
required: false | |
type: array | |
default: ["2.7"] | |
plone_version: | |
description: 'Plone version' | |
required: false | |
type: array | |
default: ["4.3"] | |
matrix_experimental: | |
description: 'Experimental matrix' | |
type: boolean | |
required: false | |
default: false | |
runner_label: | |
description: 'Runner label' | |
type: string | |
required: false | |
default: "gha-runners-delib-py2" | |
soffice: | |
description: 'Launch soffice' | |
required: false | |
type: boolean | |
default: true | |
test_command: | |
description: 'Test command' | |
required: false | |
type: string | |
default: 'bin/test' | |
install_dependencies_commands: | |
description: 'Install dependencies commands' | |
required: false | |
type: string | |
default: 'sudo pip install -r requirements-tests.txt' | |
secrets: | |
mattermost_webhook_url: | |
description: 'Webhook URL to send notifications on Mattermost, if not provided, notifications will not be sent' | |
required: false | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
test: | |
runs-on: ${{ inputs.runner_label }} | |
continue-on-error: ${{ matrix.experimental }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ${{ inputs.python_version }} | |
plone-version: ${{ inputs.plone_version }} | |
experimental: ${{ inputs.matrix_experimental }} | |
if: ${{ !github.event_name == 'pull_request' || !github.event.pull_request.draft }} | |
steps: | |
- name: Launch soffice | |
if: ${{ inputs.soffice }} | |
run: soffice '--accept=socket,host=0.0.0.0,port=2002;urp;StarOffice.ServiceManager' --nologo --headless --nofirststartwizard --norestore & | |
shell: bash | |
- name: Run tests | |
uses: IMIO/gha/plone-package-test-notify@v4 | |
env: | |
cache-name: cache-eggs | |
PM_BRANCH_NAME: ${{ inputs.branch_name || 'master' }} | |
with: | |
CACHE_KEY: ${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.python-version }} | |
TEST_COMMAND: ${{ inputs.test_command }} | |
INSTALL_DEPENDENCIES_COMMANDS: | | |
${{ inputs.install_dependencies_commands }} | |
MATTERMOST_WEBHOOK_URL: ${{ secrets.mattermost_webhook_url }} |