Browse Source

minor #2727 PHPUnit - use speedtrap (keradus)

This PR was merged into the 2.2 branch.

Discussion
----------

PHPUnit - use speedtrap

Commits
-------

d77cb73 PHPUnit - use speedtrap
Dariusz Ruminski 7 years ago
parent
commit
ccf4b7590f
2 changed files with 10 additions and 0 deletions
  1. 1 0
      composer.json
  2. 9 0
      phpunit.xml.dist

+ 1 - 0
composer.json

@@ -32,6 +32,7 @@
     },
     "require-dev": {
         "gecko-packages/gecko-php-unit": "^2.0",
+        "johnkary/phpunit-speedtrap": "^1.0.1",
         "justinrainbow/json-schema": "^5.0",
         "phpunit/phpunit": "^4.5 || ^5.0",
         "satooshi/php-coveralls": "^1.0",

+ 9 - 0
phpunit.xml.dist

@@ -28,6 +28,15 @@
     </filter>
 
     <listeners>
+        <listener class="JohnKary\PHPUnit\Listener\SpeedTrapListener">
+            <arguments>
+                <array>
+                    <element key="slowThreshold">
+                        <integer>100</integer>
+                    </element>
+                </array>
+            </arguments>
+        </listener>
         <listener class="Symfony\Bridge\PhpUnit\SymfonyTestsListener"/>
     </listeners>