Create action #4
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 Action | |
on: | |
workflow_dispatch: | |
inputs: | |
environment: | |
description: 'Environment to deploy to' | |
required: true | |
default: 'staging' | |
type: choice | |
options: | |
- staging | |
- production | |
debug_mode: | |
description: 'Enable debug mode' | |
required: false | |
type: boolean | |
default: false | |
version: | |
description: 'Version to deploy' | |
required: true | |
type: string | |
default: '1.0.0' | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
jobs: | |
test: | |
name: Test Update Input Params Action | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- 'ubuntu-latest' | |
- 'macos-latest' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Run Update Input Params Action | |
uses: ./action.yml | |
- name: Verify Summary Content | |
run: | | |
if [ ! -f "$GITHUB_STEP_SUMMARY" ]; then | |
echo "Summary file was not created!" | |
exit 1 | |
fi | |
if ! grep -q "Workflow Input Parameters" "$GITHUB_STEP_SUMMARY"; then | |
echo "Summary table header not found!" | |
exit 1 | |
fi | |
if ! grep -q "environment" "$GITHUB_STEP_SUMMARY"; then | |
echo "Expected input parameter 'environment' not found in summary!" | |
exit 1 | |
fi |