diff --git a/Build/phpunit.xml.dist b/Build/phpunit.xml.dist
index e77e1726..e5a87e24 100644
--- a/Build/phpunit.xml.dist
+++ b/Build/phpunit.xml.dist
@@ -17,6 +17,9 @@
stopOnSkipped="false"
>
+
+
+
../Tests/Functional/
diff --git a/Tests/PhpUnit/GarbageCollectionExtension.php b/Tests/PhpUnit/GarbageCollectionExtension.php
new file mode 100644
index 00000000..be05ea32
--- /dev/null
+++ b/Tests/PhpUnit/GarbageCollectionExtension.php
@@ -0,0 +1,58 @@
+registerSubscribers(
+ new class implements PreparedSubscriber {
+ public function notify(Prepared $event): void
+ {
+ gc_collect_cycles();
+ }
+ },
+ new class implements FinishedSubscriber {
+ public function notify(Finished $event): void
+ {
+ gc_collect_cycles();
+ }
+ },
+ );
+ }
+}