Skip to content
This repository has been archived by the owner on Nov 21, 2021. It is now read-only.

Commit

Permalink
migrate to github actions (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
dmaicher authored Oct 26, 2021
1 parent 5008c5e commit 8e1580e
Show file tree
Hide file tree
Showing 3 changed files with 91 additions and 38 deletions.
81 changes: 81 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
name: Build

on: [pull_request]

jobs:
tests:
runs-on: ubuntu-latest
name: Test
strategy:
fail-fast: false
matrix:
include:
- php: 7.2
- php: 7.3
SYMFONY_REQUIRE: 4.4.*
- php: 7.4
SYMFONY_REQUIRE: 5.3.*
- php: 8.0
- php: 8.1
stability: dev
SYMFONY_REQUIRE: 6.0.*

steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "${{ matrix.php }}"
coverage: none

- name: Configure Composer minimum stability
if: matrix.stability
run: composer config minimum-stability ${{ matrix.stability }}

- name: Install symfony/flex
run: composer global require symfony/flex

- name: Install dependencies
env:
SYMFONY_REQUIRE: "${{ matrix.SYMFONY_REQUIRE }}"
run: composer update ${{ matrix.composer-flags }} --prefer-dist

- name: Phpunit
run: make test

php-stan:
runs-on: ubuntu-latest
name: php-stan

steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "7.4"

- name: Install dependencies
run: composer update --prefer-dist

- name: PHPStan
run: make phpstan

cs-fixer:
runs-on: ubuntu-latest
name: CS-Fixer

steps:
- uses: actions/checkout@v2

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: "7.4"

- name: Install dependencies
run: composer update --prefer-dist

- name: PHP CS Fixer
run: make php_cs_fixer_check
38 changes: 0 additions & 38 deletions .travis.yml

This file was deleted.

10 changes: 10 additions & 0 deletions src/DataCollector.php
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,16 @@ public function failCurrentRequest(): void
$this->currentEndpoint = null;
}

public function __serialize(): array
{
return $this->data;
}

public function __unserialize(array $data): void
{
$this->data = $data;
}

public function serialize()
{
return serialize($this->data);
Expand Down

0 comments on commit 8e1580e

Please sign in to comment.