Skip to content

Commit

Permalink
Merge pull request #166 from alissn/AddGithubAction
Browse files Browse the repository at this point in the history
GitHub Action Integration for Test Automation and Composer Updates
  • Loading branch information
morilog authored May 9, 2024
2 parents a9729db + 23bfd03 commit 16a9d91
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 4 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: tests

on:
push:
pull_request:

jobs:
tests:
runs-on: ubuntu-22.04

strategy:
fail-fast: true
matrix:
php: [ 7.1, 7.2, 7.3, 7.4, 8.0, 8.1, 8.2, 8.3 ]

name: PHP ${{ matrix.php }}

steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
ini-values: error_reporting=E_ALL
tools: composer:v2
coverage: none

- name: Install dependencies
run: |
composer update --prefer-dist --no-interaction --no-progress
- name: Execute tests
run: vendor/bin/phpunit
8 changes: 4 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
],
"keywords": ["Laravel","Date","Datetime","Jalali", "Morilog"],
"require": {
"php": "^7.0 | ^7.1 | ^7.2 | ^8.0 | ^8.1",
"php": "^7.0 | ^8.0",
"nesbot/carbon": "^1.21 || ^2.0 || ^3.0",
"beberlei/assert": "3.*"
"beberlei/assert": "^3.0"
},
"require-dev" : {
"phpunit/phpunit": "~4.0"
},
"phpunit/phpunit": ">4.0"
},
"autoload": {
"psr-4": {
"Morilog\\Jalali\\": "src"
Expand Down

0 comments on commit 16a9d91

Please sign in to comment.