Skip to content

Run Create project test suite #1418

Run Create project test suite

Run Create project test suite #1418

name: Run Create project test suite
on:
push:
branches:
schedule:
- cron: '0 * * * *'
jobs:
laravel-tests:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
php: [8.0, 8.1]
version: [^3.3, dev-master, dev-develop]
mysql: [5.7.33, 5.7.37, 8.0.21]
withenv: [local]
services:
mysql:
image: mysql:${{ matrix.mysql }}
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_DATABASE: cms_test
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
name: PHP${{ matrix.php }} - ${{ matrix.version }} - ${{ matrix.mysql }}
steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, bcmath, soap, intl, gd, exif, iconv, imagick
coverage: none
- uses: actions/checkout@v2
- name: Install Dependencies
run: composer create-project --prefer-dist juzaweb/cms blog ${{ matrix.version }}
- name: Copy .env
working-directory: blog
run: rm .env && cp .env.testing.example .env
- name: Generate key
working-directory: blog
run: php artisan key:generate
- name: Clear Configuration
working-directory: blog
run: php artisan config:clear
- name: Directory Permissions
working-directory: blog
run: chmod -R 777 storage bootstrap/cache
- name: Execute tests Install
working-directory: blog
run: php artisan test modules/Tests/InstallTest.php
- name: Execute tests (Unit and Feature tests)
working-directory: blog
run: php artisan test
- name: Execute tests Update
working-directory: blog
run: php artisan test modules/Tests/UpdateTest.php