Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

Commit

Permalink
Merge pull request #518 from alecpl/dev/laravel-v9
Browse files Browse the repository at this point in the history
Support Laravel v9 + Github Actions
  • Loading branch information
Arkanius authored Mar 19, 2022
2 parents 43d0878 + 2be1bc1 commit 4db6c7e
Show file tree
Hide file tree
Showing 7 changed files with 58 additions and 15 deletions.
43 changes: 43 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: tests

on:
push:
pull_request:

jobs:
linux_tests:
runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[ci skip]')"

strategy:
fail-fast: true
matrix:
include:
- php: "7.3"
framework: "laravel/framework:^8.0"
- php: "7.4"
framework: "laravel/framework:^8.0"
- php: "8.0"
framework: "laravel/framework:^8.0"
- php: "8.0"
framework: "laravel/framework:^9.0"

name: PHP ${{ matrix.php }} (${{ matrix.framework }})

steps:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
extensions: swoole

- name: Checkout code
uses: actions/checkout@v2

- name: Install dependencies
run: |
composer require ${{ matrix.framework }} --no-update -n
COMPOSER_MEMORY_LIMIT=-1 composer install --prefer-dist -n -o
- name: Execute tests
run: vendor/bin/phpunit
2 changes: 1 addition & 1 deletion .scrutinizer.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
build:
environment:
php: 7.2
php: 7.3

filter:
excluded_paths:
Expand Down
20 changes: 10 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,20 +22,20 @@
],
"require": {
"php": "^7.2|^8.0",
"illuminate/console": "~5.4|~6.0|~7.0|~8.0",
"illuminate/contracts": "~5.4|~6.0|~7.0|~8.0",
"illuminate/http": "~5.4|~6.0|~7.0|~8.0",
"illuminate/support": "~5.4|~6.0|~7.0|~8.0",
"illuminate/console": "~5.4|~6.0|~7.0|~8.0|~9.0",
"illuminate/contracts": "~5.4|~6.0|~7.0|~8.0|~9.0",
"illuminate/http": "~5.4|~6.0|~7.0|~8.0|~9.0",
"illuminate/support": "~5.4|~6.0|~7.0|~8.0|~9.0",
"predis/predis": "^1.1"
},
"require-dev": {
"laravel/lumen-framework": "~5.4|~6.0|~7.0|~8.0",
"phpunit/phpunit": "^7.5",
"phpunit/php-code-coverage": "^6.1",
"laravel/lumen-framework": "~5.4|~6.0|~7.0|~8.0|~9.0",
"phpunit/phpunit": "^9",
"phpunit/php-code-coverage": "^9",
"php-coveralls/php-coveralls": "^2.1",
"mockery/mockery": "~1.0",
"codedungeon/phpunit-result-printer": "^0.14.0",
"php-mock/php-mock": "^2.0",
"mockery/mockery": "~1.5",
"codedungeon/phpunit-result-printer": "^0.31.0",
"php-mock/php-mock": "^2.3",
"swoole/ide-helper": "@dev"
},
"autoload": {
Expand Down
2 changes: 1 addition & 1 deletion tests/Coroutine/ConnectorFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
*/
class ConnectorFactoryTest extends TestCase
{
public function setUp()
public function setUp(): void
{
parent::setUp();
$this->mockEnv('Laravel\Lumen');
Expand Down
2 changes: 1 addition & 1 deletion tests/Task/QueueFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
*/
class QueueFactoryTest extends TestCase
{
public function setUp()
public function setUp(): void
{
parent::setUp();
$this->mockEnv('Laravel\Lumen');
Expand Down
2 changes: 1 addition & 1 deletion tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

class TestCase extends BaseTestCase
{
public function tearDown()
public function tearDown(): void
{
$this->addToAssertionCount(
m::getContainer()->mockery_getExpectationCount()
Expand Down
2 changes: 1 addition & 1 deletion tests/Websocket/TableRoomTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class TableRoomTest extends TestCase
{
protected $tableRoom;

public function setUp()
public function setUp(): void
{
$config = [
'room_rows' => 4096,
Expand Down

0 comments on commit 4db6c7e

Please sign in to comment.