Skip to content

test: rewrite Pest tests as PHPUnit tests#22

Merged
AlwinGarside merged 1 commit intomainfrom
feature/phpunit
Feb 7, 2026
Merged

test: rewrite Pest tests as PHPUnit tests#22
AlwinGarside merged 1 commit intomainfrom
feature/phpunit

Conversation

@AlwinGarside
Copy link
Contributor

No description provided.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to migrate from Pest to PHPUnit as the testing framework. It removes Pest dependencies and configuration files, converts some array-related tests to PHPUnit format in the tests/Unit/array/ directory, and updates the CI workflow to use PHPUnit/Paratest instead of Pest.

Changes:

  • Removed Pest configuration (tests/Pest.php, tests/TestCase.php, Pest stub files)
  • Converted 8 array function tests from Pest to PHPUnit format
  • Added numerous new Pest test files in a new pests/ directory
  • Updated composer.json to replace Pest with PHPUnit and Paratest dependencies
  • Updated PHPUnit and PHPStan configurations
  • Updated GitHub Actions workflow to run tests with Paratest

Reviewed changes

Copilot reviewed 21 out of 52 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
tests/Unit/array/functionsTest.php Deleted original Pest test file containing array function tests
tests/Unit/array/*.php (8 files) New PHPUnit test classes for array functions (exclude, extract, get, interchange, key_types, omit, pick, remap)
tests/TestCase.php Deleted base test case class
tests/Pest.php Deleted Pest configuration file
stubs/Pest/*.stub.php Deleted Pest stub files for IDE support
pests/Unit/**/*.php Added new Pest test files (appears to be newly added, not converted)
pests/Datasets/*.php Added Pest dataset files
phpunit.dist.xml Updated to configure PHPUnit test suites
phpstan.dist.neon Removed Pest-specific configuration, added PHPUnit extension
composer.json Replaced Pest with PHPUnit/Paratest, updated test script
.github/workflows/tests.yml Updated to run Paratest instead of Pest

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@empaphy empaphy deleted a comment from Copilot AI Feb 1, 2026
@AlwinGarside AlwinGarside force-pushed the feature/phpunit branch 5 times, most recently from aae334e to 0820caa Compare February 6, 2026 00:53
@AlwinGarside AlwinGarside marked this pull request as ready for review February 6, 2026 08:56
@AlwinGarside AlwinGarside force-pushed the feature/phpunit branch 8 times, most recently from a1e37dd to 74fceeb Compare February 7, 2026 13:03
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@empaphy empaphy deleted a comment from Copilot AI Feb 7, 2026
@AlwinGarside AlwinGarside force-pushed the feature/phpunit branch 5 times, most recently from 076bcc5 to f4e1f57 Compare February 7, 2026 13:55
@AlwinGarside AlwinGarside force-pushed the feature/phpunit branch 11 times, most recently from e59f8f2 to cedcf5f Compare February 7, 2026 15:03
@empaphy empaphy deleted a comment from github-actions bot Feb 7, 2026
@empaphy empaphy deleted a comment from github-actions bot Feb 7, 2026
@empaphy empaphy deleted a comment from github-actions bot Feb 7, 2026
@AlwinGarside AlwinGarside force-pushed the feature/phpunit branch 4 times, most recently from 1aac2e2 to deb41e0 Compare February 7, 2026 15:49
@empaphy empaphy deleted a comment from github-actions bot Feb 7, 2026
@github-actions
Copy link

github-actions bot commented Feb 7, 2026

Code Coverage

Package Line Rate Branch Rate Complexity Health
array.php 100% 100% 41
debug.php 100% 100% 5
Enumerations/EnumDynamicity.php 100% 100% 4
Fallback.php 100% 100% NaN
generators.php 100% 100% 14
Math/functions.php 100% 100% 21
other.php 100% 100% 12
Path/functions.php 100% 100% 42
Path/PathInfo.php 100% 100% 1
pcre.php 100% 100% 5
Sorting/Direction.php 100% 100% NaN
Sorting/Type.php 100% 100% NaN
Type/functions.php 100% 100% 7
Var/functions.php 100% 100% 20
Var/Type.php 100% 100% 3
Summary 100% (363 / 363) 100% (0 / 0) NaN

@AlwinGarside AlwinGarside merged commit 416b00f into main Feb 7, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants