fix dataset key

This commit is contained in:
nuno maduro
2026-08-03 16:47:34 -04:00
parent 7d187dd50a
commit 3223d50607
2 changed files with 8 additions and 2 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(