Skip to content

Commit

Permalink
release: 3.7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
nunomaduro committed Jan 19, 2025
1 parent 150bb94 commit 6afb365
Show file tree
Hide file tree
Showing 12 changed files with 20 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
with:
php-version: ${{ matrix.php }}
tools: composer:v2
coverage: none
coverage: xdebug

- name: Setup Problem Matches
run: |
Expand Down
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@
"pestphp/pest-plugin": "^3.0.0",
"pestphp/pest-plugin-arch": "^3.0.0",
"pestphp/pest-plugin-mutate": "^3.0.5",
"phpunit/phpunit": "^11.5.1"
"phpunit/phpunit": "^11.5.3"
},
"conflict": {
"filp/whoops": "<2.16.0",
"phpunit/phpunit": ">11.5.1",
"phpunit/phpunit": ">11.5.3",
"sebastian/exporter": "<6.0.0",
"webmozart/assert": "<1.11.0"
},
Expand All @@ -54,7 +54,7 @@
},
"require-dev": {
"pestphp/pest-dev-tools": "^3.3.0",
"pestphp/pest-plugin-type-coverage": "^3.2.0",
"pestphp/pest-plugin-type-coverage": "^3.2.3",
"symfony/process": "^7.2.0"
},
"minimum-stability": "dev",
Expand Down
2 changes: 1 addition & 1 deletion overrides/Logging/JUnit/JunitXmlLogger.php
Original file line number Diff line number Diff line change
Expand Up @@ -446,7 +446,7 @@ private function createTestCase(Errored|Failed|MarkedIncomplete|PreparationStart
if ($test->isTestMethod()) {
assert($test instanceof TestMethod);

//$testCase->setAttribute('line', (string) $test->line()); // pest-removed
// $testCase->setAttribute('line', (string) $test->line()); // pest-removed
$className = $this->converter->getTrimmedTestClassName($test); // pest-added
$testCase->setAttribute('class', $className); // pest-changed
$testCase->setAttribute('classname', str_replace('\\', '.', $className)); // pest-changed
Expand Down
2 changes: 1 addition & 1 deletion src/Bootstrappers/BootOverrides.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ final class BootOverrides implements Bootstrapper
'8abdad6413329c6fe0d7d44a8b9926e390af32c0b3123f3720bb9c5bbc6fbb7e' => 'TextUI/Output/Default/ProgressPrinter/Subscriber/TestSkippedSubscriber.php',
'b4250fc3ffad5954624cb5e682fd940b874e8d3422fa1ee298bd7225e1aa5fc2' => 'TextUI/TestSuiteFilterProcessor.php',
'8cfcb4999af79463eca51a42058e502ea4ddc776cba5677bf2f8eb6093e21a5c' => 'Event/Value/ThrowableBuilder.php',
'ede161507d4c9c27805f55a05a32c3bb528e53b6e1fc092bfafdb8207e0019e9' => 'Logging/JUnit/JunitXmlLogger.php',
'86cd9bcaa53cdd59c5b13e58f30064a015c549501e7629d93b96893d4dee1eb1' => 'Logging/JUnit/JunitXmlLogger.php',
];

/**
Expand Down
6 changes: 4 additions & 2 deletions src/Logging/Converter.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
use PHPUnit\Event\Code\Test;
use PHPUnit\Event\Code\TestMethod;
use PHPUnit\Event\Code\Throwable;
use PHPUnit\Event\Test\AfterLastTestMethodErrored;
use PHPUnit\Event\Test\BeforeFirstTestMethodErrored;
use PHPUnit\Event\Test\ConsideredRisky;
use PHPUnit\Event\Test\Errored;
Expand Down Expand Up @@ -254,8 +255,9 @@ public function getStateFromResult(PhpUnitTestResult $result): State
$numberOfNotPassedTests = count(
array_unique(
array_map(
function (BeforeFirstTestMethodErrored|Errored|Failed|Skipped|ConsideredRisky|MarkedIncomplete $event): string {
if ($event instanceof BeforeFirstTestMethodErrored) {
function (AfterLastTestMethodErrored|BeforeFirstTestMethodErrored|Errored|Failed|Skipped|ConsideredRisky|MarkedIncomplete $event): string {
if ($event instanceof BeforeFirstTestMethodErrored
|| $event instanceof AfterLastTestMethodErrored) {
return $event->testClassName();
}

Expand Down
2 changes: 1 addition & 1 deletion src/Pest.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

function version(): string
{
return '3.7.1';
return '3.7.2';
}

function testDirectory(string $file = ''): string
Expand Down
1 change: 1 addition & 0 deletions src/Support/StateGenerator.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ public function fromPhpUnitTestResult(int $passedTests, PHPUnitTestResult $testR
$testResultEvent->throwable()
));
} else {
// @phpstan-ignore-next-line
$state->add(TestResult::fromBeforeFirstTestMethodErrored($testResultEvent));
}
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

Pest Testing Framework 3.7.1.
Pest Testing Framework 3.7.2.

USAGE: pest <file> [options]

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@

Pest Testing Framework 3.7.1.
Pest Testing Framework 3.7.2.

6 changes: 3 additions & 3 deletions tests/.snapshots/success.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@
↓ is marked as todo 3
↓ shouldBeMarkedAsTodo

WARN Tests\Features\Coverage
PASS Tests\Features\Coverage
✓ it has plugin
- it adds coverage if --coverage exist → Coverage is not available
it adds coverage if --coverage exist
✓ it adds coverage if --min exist
✓ it generates coverage based on file input

Expand Down Expand Up @@ -1708,4 +1708,4 @@
WARN Tests\Visual\Version
- visual snapshot of help command output

Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 38 todos, 33 skipped, 1152 passed (2744 assertions)
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 38 todos, 32 skipped, 1153 passed (2749 assertions)
4 changes: 2 additions & 2 deletions tests/Features/DescriptionLess.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function get(string $route)
get('foo')->expect(true)->toBeTrue();

describe('a "describe" group of tests', function () {
get('foo'); // not incomplete because closure is created...
get('foo'); // not incomplete because closure is created...
get('foo')->get('bar')->expect(true)->toBeTrue();
get('foo')->expect(true)->toBeTrue();
});
});
2 changes: 1 addition & 1 deletion tests/Visual/Parallel.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

test('parallel', function () use ($run) {
expect($run('--exclude-group=integration'))
->toContain('Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 38 todos, 24 skipped, 1142 passed (2720 assertions)')
->toContain('Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 38 todos, 23 skipped, 1143 passed (2725 assertions)')
->toContain('Parallel: 3 processes');
})->skipOnWindows();

Expand Down

0 comments on commit 6afb365

Please sign in to comment.