Skip to content

Commit

Permalink
test: upload logs as artefact (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
andreiio authored Jun 6, 2024
1 parent 59c3872 commit 5e9437b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
fail-fast: false
matrix:
php-version:
- "8.2"
- '8.2'

env:
extensions: mbstring, sqlite, intl, gd
Expand Down Expand Up @@ -64,3 +64,10 @@ jobs:
- name: Run tests
run: php artisan test

- name: Upload logs
if: always()
uses: actions/upload-artifact@v4
with:
name: php-${{ matrix.php-version }}-logs
path: storage/logs/laravel.log
3 changes: 3 additions & 0 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,13 @@

namespace Tests;

use Illuminate\Foundation\Testing\RefreshDatabase;
use Illuminate\Foundation\Testing\TestCase as BaseTestCase;

abstract class TestCase extends BaseTestCase
{
use RefreshDatabase;

protected function setUp(): void
{
parent::setUp();
Expand Down

0 comments on commit 5e9437b

Please sign in to comment.