aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/json2phpunit.php
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2025-07-29 20:13:11 +0900
committernsfisis <nsfisis@gmail.com>2025-07-29 20:13:11 +0900
commit7380f5614bb262a57329c53714a148331efaa109 (patch)
treec1e30abd052833952922f43c97abc1016bab598c /tools/json2phpunit.php
parent05724af3db760abe7fcd6a563423193b50bc744d (diff)
downloadphp-waddiwasi-7380f5614bb262a57329c53714a148331efaa109.tar.gz
php-waddiwasi-7380f5614bb262a57329c53714a148331efaa109.tar.zst
php-waddiwasi-7380f5614bb262a57329c53714a148331efaa109.zip
test: Speed up test execution by removing test case dependencies
Diffstat (limited to 'tools/json2phpunit.php')
-rw-r--r--tools/json2phpunit.php6
1 files changed, 0 insertions, 6 deletions
diff --git a/tools/json2phpunit.php b/tools/json2phpunit.php
index 5188606..901683b 100644
--- a/tools/json2phpunit.php
+++ b/tools/json2phpunit.php
@@ -55,12 +55,10 @@ foreach ($wastJsonFiles as $wastJsonFile) {
fwrite($fp, "declare(strict_types=1);\n\n");
fwrite($fp, "namespace Nsfisis\\Waddiwasi\\Tests\\SpecTestsuites\\Core;\n\n");
fwrite($fp, "use Nsfisis\\Waddiwasi\\Tests\\SpecTestsuites\\SpecTestsuiteBase;\n");
- fwrite($fp, "use PHPUnit\\Framework\\Attributes\\Depends;\n");
fwrite($fp, "use PHPUnit\\Framework\\Attributes\\DoesNotPerformAssertions;\n\n");
fwrite($fp, "final class $className extends SpecTestsuiteBase\n");
fwrite($fp, "{\n");
- $prevMethodName = null;
foreach ($commands as $i => $command) {
$type = $command['type'];
$line = $command['line'];
@@ -82,9 +80,6 @@ foreach ($wastJsonFiles as $wastJsonFile) {
if ($commandTest === null) {
fwrite($fp, " #[DoesNotPerformAssertions]\n");
}
- if ($prevMethodName !== null) {
- fwrite($fp, " #[Depends('$prevMethodName')]\n");
- }
fwrite($fp, " public function $methodName(): void\n");
fwrite($fp, " {\n");
@@ -102,7 +97,6 @@ foreach ($wastJsonFiles as $wastJsonFile) {
if ($i !== count($commands) - 1) {
fwrite($fp, "\n");
}
- $prevMethodName = $methodName;
}
fwrite($fp, "}\n");