Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Supports Paratests and Fixes PHPUnit 11 Supports #179

Merged
merged 29 commits into from
Feb 9, 2024
Merged
Show file tree
Hide file tree
Changes from 27 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
51 changes: 47 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:

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

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand All @@ -41,9 +41,52 @@ jobs:

- name: Install dependencies
run: |
composer require phpunit/phpunit:^${{ matrix.phpunit }} --no-update
composer require "laravel/framework=^${{ matrix.laravel }}" --no-update
composer update --prefer-dist --no-interaction --no-progress
composer update --with=laravel/framework=^${{ matrix.laravel }} --with=phpunit/phpunit:^${{ matrix.phpunit }} --prefer-dist --no-interaction --no-progress

- name: Execute tests
run: vendor/bin/phpunit

paratests:
runs-on: ubuntu-22.04

strategy:
fail-fast: true
matrix:
php: [8.2, 8.3]

name: PHP ${{ matrix.php }} Paratest

services:
mysql:
image: mysql:8
env:
MYSQL_ALLOW_EMPTY_PASSWORD: yes
MYSQL_DATABASE: laravel
ports:
- 3306:3306
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3

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

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

- name: Install dependencies
run: |
composer require "nunomaduro/collision" "brianium/paratest" --no-update
composer update --prefer-dist --no-interaction --no-progress -W

- name: Execute tests
run: php vendor/bin/testbench package:test --parallel
env:
DB_CONNECTION: mysql
DB_USERNAME: root
DB_DATABASE: laravel
10 changes: 3 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,17 @@
"require": {
"php": "^8.2",
"ext-dom": "*",
"illuminate/contracts": "^10.0|^11.0",
"illuminate/database": "^10.0|^11.0",
"illuminate/http": "^10.0|^11.0",
"illuminate/support": "^10.0|^11.0",
"illuminate/testing": "^10.0|^11.0",
"laravel/framework": "^10.44|^11.0",
"mockery/mockery": "^1.0",
"phpunit/phpunit": "^10.4|^11.0",
"phpunit/phpunit": "^10.4|^11.0.1",
"symfony/console": "^6.2|^7.0",
"symfony/css-selector": "^6.2|^7.0",
"symfony/dom-crawler": "^6.2|^7.0",
"symfony/http-foundation": "^6.2|^7.0",
"symfony/http-kernel": "^6.2|^7.0"
},
"require-dev": {
"laravel/framework": "^10.0|^11.0"
"orchestra/testbench-core": "^8.21|^9.0"
},
"autoload": {
"psr-4": {
Expand Down
2 changes: 1 addition & 1 deletion phpunit.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
>
<testsuites>
<testsuite name="Unit">
<directory suffix="Test.php">./tests</directory>
<directory suffix="Test.php">./tests</directory>
</testsuite>
</testsuites>
</phpunit>
82 changes: 0 additions & 82 deletions src/Constraints/Concerns/FormFieldConstraint.php

This file was deleted.

99 changes: 0 additions & 99 deletions src/Constraints/Concerns/HasElement.php

This file was deleted.

78 changes: 0 additions & 78 deletions src/Constraints/Concerns/HasInElement.php

This file was deleted.