Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
859b748
commit dd90b62
Showing
18 changed files
with
2,147 additions
and
990 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
|
||
name: 'Test' | ||
description: "Run test bundle" | ||
inputs: | ||
php_version: | ||
description: 'Set php version' | ||
required: true | ||
default: '8.0' | ||
symfony_version: | ||
description: 'Set symfony version' | ||
required: true | ||
default: '' | ||
composer_flags: | ||
description: 'Composer extra args' | ||
required: true | ||
default: '' | ||
github_token: | ||
description: 'Token for deploy corverage' | ||
required: true | ||
discord_webhook: | ||
description: 'Discord webhook' | ||
required: true | ||
|
||
runs: | ||
using: "composite" | ||
steps: | ||
- name: Setup PHP | ||
uses: shivammathur/setup-php@v2 | ||
with: | ||
php-version: ${{ inputs.php_version }}. | ||
|
||
- name: Update composer | ||
shell: bash | ||
run: composer self-update | ||
|
||
- name: Validate composer.json and composer.lock | ||
shell: bash | ||
run: composer validate --strict | ||
|
||
- name: Intsall Symfony | ||
shell: bash | ||
run: | | ||
if [ "${{ inputs.symfony_version }}" != "" ]; then composer require "symfony/symfony:${{ inputs.symfony_version }}" --no-update; fi; | ||
if [ "${{ inputs.php_version }}" == "7.2" ]; then composer require --dev "phpunit/phpunit:8.5" --no-update; fi; | ||
composer update --prefer-dist --no-interaction $composer_flags | ||
- name: Run tests | ||
shell: bash | ||
run: | | ||
mkdir -p build/logs | ||
vendor/bin/phpunit --coverage-text --coverage-clover build/logs/clover.xml --whitelist src tests/ | ||
- name: Upload coverage results to Coveralls | ||
if: success() | ||
env: | ||
COVERALLS_REPO_TOKEN: ${{ inputs.github_token }} | ||
shell: bash | ||
run: | | ||
composer global require php-coveralls/php-coveralls | ||
php-coveralls --coverage_clover=build/logs/clover.xml -v | ||
- name: Notify discord success | ||
uses: th0th/notify-discord@v0.4.1 | ||
if: ${{ success() }} | ||
env: | ||
DISCORD_WEBHOOK_URL: ${{ inputs.discord_webhook }} | ||
GITHUB_ACTOR: ${{ github.actor }} | ||
GITHUB_JOB_NAME: "Build and deploy" | ||
GITHUB_JOB_STATUS: 'success' | ||
|
||
- name: Notify discord failure | ||
uses: th0th/notify-discord@v0.4.1 | ||
if: ${{ failure() }} | ||
env: | ||
DISCORD_WEBHOOK_URL: ${{ inputs.discord_webhook }} | ||
GITHUB_ACTOR: ${{ github.actor }} | ||
GITHUB_JOB_NAME: "Build and deploy" | ||
GITHUB_JOB_STATUS: 'failure' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: PHP 7.2 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
php_version: '7.2' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: PHP 7.3 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
php_version: '7.3' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: PHP 7.4 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
php_version: '7.4' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: PHP 8.0 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
php_version: '8.0' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: PHP 8.1 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
php_version: '8.1' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Symfony 4.4 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '4.4' | ||
php_version: '7.2' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Symfony 5.0 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '5.0' | ||
php_version: '7.2' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Symfony 5.1 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '5.1' | ||
php_version: '7.2' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Symfony 5.2 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '5.2' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Symfony 5.3 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '5.3' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Symfony 5.4 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '5.4' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: Symfony 6.0 | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
pull_request: | ||
branches: [ master ] | ||
create: | ||
tags: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: ./.github/actions/test | ||
with: | ||
symfony_version: '6.0' | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
discord_webhook: ${{ secrets.DISCORD_WEBHOOK }} |
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
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
Oops, something went wrong.