Skip to content

Commit

Permalink
Merge pull request #120 from laravel-notification-channels/gha
Browse files Browse the repository at this point in the history
Attempt to use GitHub Actions
  • Loading branch information
dwightwatson authored Feb 25, 2021
2 parents 31097d9 + f2fd701 commit f49bce6
Show file tree
Hide file tree
Showing 5 changed files with 60 additions and 74 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: build

on:
push:
pull_request:

jobs:
test:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
php: [8.0, 7.4, 7.3]
laravel: [8.*, 7.*, 6.*]
dependency-version: [prefer-lowest, prefer-stable]
os: [ubuntu-latest]
include:
- laravel: 8.*

name: PHP ${{ matrix.php }} - Laravel ${{ matrix.laravel }} - ${{ matrix.dependency-version }}

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

- name: Cache dependencies
uses: actions/cache@v1
with:
path: ~/.composer/cache/files
key: dependencies-laravel-${{ matrix.laravel }}-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: dom, curl, libxml, mbstring, zip, pcntl, pdo, sqlite, pdo_sqlite, mysql, mysqli, pdo_mysql, bcmath, soap, intl, gd, exif, iconv, imagick
coverage: none

- name: Install dependencies
run: |
composer require "laravel/framework:${{ matrix.laravel }}" --no-interaction --no-update
composer update --${{ matrix.dependency-version }} --prefer-dist --no-interaction --no-suggest
- name: Execute tests
run: vendor/bin/phpunit
21 changes: 0 additions & 21 deletions .scrutinizer.yml

This file was deleted.

22 changes: 0 additions & 22 deletions .travis.yml

This file was deleted.

10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
"require": {
"php": "^7.3|^8.0",
"edamov/pushok": "^0.12",
"illuminate/cache": "^8.0",
"illuminate/config": "^8.0",
"illuminate/events": "^8.0",
"illuminate/notifications": "^8.0",
"illuminate/support": "^8.0"
"illuminate/cache": "^6.0|^7.0|^8.0",
"illuminate/config": "^6.0|^7.0|^8.0",
"illuminate/events": "^6.0|^7.0|^8.0",
"illuminate/notifications": "^6.0|^7.0|^8.0",
"illuminate/support": "^6.0|^7.0|^8.0"
},
"require-dev": {
"mockery/mockery": "^1.4",
Expand Down
37 changes: 11 additions & 26 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,28 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="vendor/autoload.php"
backupGlobals="false"
backupStaticAttributes="false"
colors="true"
verbose="true"
convertErrorsToExceptions="true"
convertNoticesToExceptions="true"
convertWarningsToExceptions="true"
processIsolation="false"
stopOnFailure="false">
<testsuites>
<testsuite name=":service_name Test Suite">
<directory>tests</directory>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory suffix=".php">src/</directory>
</whitelist>
</filter>
<logging>
<log type="junit" target="build/report.junit.xml"/>
<log type="coverage-html" target="build/coverage"/>
<log type="coverage-text" target="build/coverage.txt"/>
<log type="coverage-clover" target="build/logs/clover.xml"/>
</logging>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="vendor/autoload.php" backupGlobals="false" backupStaticAttributes="false" colors="true" verbose="true" convertErrorsToExceptions="true" convertNoticesToExceptions="true" convertWarningsToExceptions="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd">
<coverage>
<include>
<directory suffix=".php">src/</directory>
</include>
</coverage>
<testsuites>
<testsuite name=":service_name Test Suite">
<directory>tests</directory>
</testsuite>
</testsuites>
</phpunit>

0 comments on commit f49bce6

Please sign in to comment.