Skip to content

Commit a1e4353

Browse files
committed
fix: change tests and test patterns
1 parent ca0bd73 commit a1e4353

File tree

4 files changed

+16
-8
lines changed

4 files changed

+16
-8
lines changed

tests/unit-blunder-event.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,9 @@
88
use MaplePHP\Blunder\Handlers\SilentHandler;
99
use MaplePHP\Blunder\Run;
1010
use MaplePHP\Unitary\Config\TestConfig;
11-
use MaplePHP\Unitary\Unit;
1211

1312
$config = TestConfig::make()->withName("blunder");
14-
$config = $config->withSubject("MaplePHP Blunder event test")->withSkip();
13+
$config = $config->withSubject("MaplePHP Blunder event test");
1514

1615
// If you add true to Unit it will run in quite mode
1716
// and only report if it finds any errors!

tests/unit-blunder-handlers.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,9 @@
1313
use MaplePHP\Blunder\Handlers\XmlHandler;
1414
use MaplePHP\Blunder\Run;
1515
use MaplePHP\Unitary\Config\TestConfig;
16-
use MaplePHP\Unitary\Unit;
17-
1816

1917
$config = TestConfig::make()->withName("blunder");
20-
$config = $config->withSubject("MaplePHP Blunder handler test")->withSkip();
18+
$config = $config->withSubject("MaplePHP Blunder handler test");
2119

2220
group($config, function (\MaplePHP\Unitary\TestCase $inst) {
2321

tests/unit-blunder-redirect.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,12 @@
77
use MaplePHP\Blunder\Handlers\SilentHandler;
88
use MaplePHP\Blunder\Run;
99
use MaplePHP\Unitary\Config\TestConfig;
10-
use MaplePHP\Unitary\Unit;
1110

1211
// If you add true to Unit it will run in quite mode
1312
// and only report if it finds any errors!
1413

1514
$config = TestConfig::make()->withName("blunder");
16-
$config = $config->withSubject("MaplePHP Blunder redirect test")->withSkip();
15+
$config = $config->withSubject("MaplePHP Blunder redirect test");
1716
group($config, function ($inst) {
1817

1918
// SilentHandler will hide the error that I have added in this file
@@ -32,7 +31,7 @@
3231
]);
3332

3433
$inst->add(basename($errFile), [
35-
'equal' => 'unitary-blunder-redirect.php'
34+
'equal' => 'unit-blunder-redirect.php'
3635
]);
3736

3837
$inst->add(basename($errLine), [

unitary.config.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?php
2+
3+
/**
4+
* Default configs, that exists in MaplePHP Unitary
5+
*/
6+
return [
7+
// # Custom discovery pattern to avoid the "Inception" problem ;)
8+
// Custom discovery pattern to prevent conflicts when testing multiple
9+
// MaplePHP libraries simultaneously. This avoids collisions with the
10+
// Blunder initialization instance inside Unitary.
11+
'discoverPattern' => "unit-*.php",
12+
];

0 commit comments

Comments
 (0)