Compare commits

..

3 Commits

Author SHA1 Message Date
nuno maduro 5b2293f67a release: v4.7.8 2026-08-03 16:49:44 -04:00
nuno maduro 7d49828491 chore: adjusts snapshots 2026-08-03 16:49:35 -04:00
nuno maduro 3223d50607 fix dataset key 2026-08-03 16:47:34 -04:00
7 changed files with 15 additions and 8 deletions
+2 -2
View File
@@ -235,8 +235,8 @@ final class TestCaseMethodFactory
$attributesCode
public function $methodName(...\$arguments)
{
if (count(\$arguments) === 1 && \$arguments[0] instanceof __PestDatasetProviderError) {
throw \$arguments[0]->getPrevious() ?? \$arguments[0];
if (count(\$arguments) === 1 && \$arguments[array_key_first(\$arguments)] instanceof __PestDatasetProviderError) {
throw \$arguments[array_key_first(\$arguments)]->getPrevious() ?? \$arguments[array_key_first(\$arguments)];
}
return \$this->__runTest(
+1 -1
View File
@@ -6,7 +6,7 @@ namespace Pest;
function version(): string
{
return '4.7.7';
return '4.7.8';
}
function testDirectory(string $file = ''): string
@@ -1,5 +1,5 @@
Pest Testing Framework 4.7.7.
Pest Testing Framework 4.7.8.
USAGE: pest <file> [options]
@@ -1,3 +1,3 @@
Pest Testing Framework 4.7.7.
Pest Testing Framework 4.7.8.
+2 -1
View File
@@ -275,6 +275,7 @@
✓ dataset items can mix named and sequential styles with ('Taylor', 'taylor@laravel.com')
✓ dataset items can mix named and sequential styles with ('James', 'james@laravel.com') #1
✓ dataset items can mix named and sequential styles with ('James', 'james@laravel.com') #2
✓ named parameters work with a single argument with ('Taylor')
PASS Tests\Features\Depends
✓ first
@@ -1905,4 +1906,4 @@
✓ pass with dataset with ('my-datas-set-value')
✓ within describe → pass with dataset with ('my-datas-set-value')
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 40 todos, 35 skipped, 1296 passed (2979 assertions)
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 40 todos, 35 skipped, 1297 passed (2980 assertions)
+6
View File
@@ -542,3 +542,9 @@ test('dataset items can mix named and sequential styles', function (string $name
['James', 'james@laravel.com'],
['James', 'email' => 'james@laravel.com'],
]);
test('named parameters work with a single argument', function (string $name) {
expect($name)->toBe('Taylor');
})->with([
['name' => 'Taylor'],
]);
+2 -2
View File
@@ -24,13 +24,13 @@ test('parallel', function () use ($run) {
$file = file_get_contents(__FILE__);
$file = preg_replace(
'/\$expected = \'.*?\';/',
"\$expected = '2 deprecated, 4 warnings, 5 incomplete, 3 notices, 40 todos, 27 skipped, 1280 passed (2928 assertions)';",
"\$expected = '2 deprecated, 4 warnings, 5 incomplete, 3 notices, 40 todos, 27 skipped, 1281 passed (2929 assertions)';",
$file,
);
file_put_contents(__FILE__, $file);
}
$expected = '2 deprecated, 4 warnings, 5 incomplete, 3 notices, 40 todos, 27 skipped, 1280 passed (2928 assertions)';
$expected = '2 deprecated, 4 warnings, 5 incomplete, 3 notices, 40 todos, 27 skipped, 1281 passed (2929 assertions)';
expect($output)
->toContain("Tests: {$expected}")