This repository has been archived by the owner on Jul 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
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
8743e07
commit abf4089
Showing
2 changed files
with
93 additions
and
0 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,55 @@ | ||
name: SWE Web App CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- develop | ||
- master | ||
- feature/** | ||
pull_request: | ||
branches: | ||
- develop | ||
- master | ||
- feature/** | ||
|
||
jobs: | ||
laravel-tests: | ||
|
||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Checkout repo content | ||
uses: actions/checkout@v2 | ||
- name: Copy .env | ||
run: php -r "file_exists('.env') || copy('.env.example', '.env');" | ||
- name: Install Dependencies | ||
# run: composer install -q --no-ansi --no-interaction --no-scripts --no-suggest --no-progress --prefer-dist | ||
run: composer install | ||
- name: Generate key | ||
run: php artisan key:generate | ||
- name: Directory Permissions | ||
run: chmod -R 777 storage bootstrap/cache | ||
- name: Create Database | ||
run: touch database/database.sqlite | ||
- name: Execute tests (Unit and Feature tests) via PHPUnit | ||
env: | ||
DB_CONNECTION: sqlite | ||
DB_DATABASE: database/database.sqlite | ||
run: vendor/bin/phpunit -c phpunit.xml | ||
- name: Report to Coveralls | ||
env: | ||
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_LARAVEL }} | ||
run: vendor/bin/php-coveralls -v | ||
- name: Slack Notification | ||
uses: homoluctus/slatify@v2.0.1 | ||
if: failure() | ||
with: | ||
type: ${{ job.status }} | ||
job_name: 'CI Check' | ||
mention: 'here' | ||
mention_if: 'failure' | ||
channel: '#devops_software' | ||
username: 'CI Checker' | ||
url: ${{ secrets.SLACK_SW_WEBHOOK }} | ||
commit: true | ||
token: ${{ secrets.GITHUB_TOKEN }} |
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,38 @@ | ||
name: Repository Checker | ||
|
||
on: [push, pull_request] | ||
|
||
jobs: | ||
repo_checker: | ||
runs-on: ubuntu-latest | ||
steps: | ||
|
||
- name: Checkout repository contents | ||
uses: actions/checkout@v2 | ||
|
||
- name: Checking for .DS_Store files | ||
uses: Maxelweb/ds-store-patrol@v1 | ||
|
||
- name: Check file existence | ||
id: check_files | ||
uses: andstor/file-existence-action@v1 | ||
with: | ||
files: LICENSE, README.md, .gitignore" | ||
|
||
- name: File exists | ||
if: steps.check_files.outputs.files_exists == 'true' | ||
run: echo All files exists! Thanks god. | ||
|
||
- name: Slack Notification | ||
uses: homoluctus/slatify@v2.0.1 | ||
if: failure() | ||
with: | ||
type: ${{ job.status }} | ||
job_name: 'Repo check' | ||
mention: 'here' | ||
mention_if: 'failure' | ||
channel: '#devops_repositories' | ||
username: 'Repo checker' | ||
url: ${{ secrets.SLACK_REPO_WEBHOOK }} | ||
commit: true | ||
token: ${{ secrets.GITHUB_TOKEN }} |