Skip to content

Commit 8570c60

Browse files
committed
Fix test
1 parent b9088e4 commit 8570c60

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

phpunit.xml.dist

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="vendor/autoload.php" backupGlobals="false" colors="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.0/phpunit.xsd" cacheDirectory=".phpunit.cache" backupStaticProperties="false">
3-
<coverage>
4-
<include>
5-
<directory suffix=".php">src/</directory>
6-
</include>
7-
</coverage>
2+
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="vendor/autoload.php" backupGlobals="false" colors="true" processIsolation="false" stopOnFailure="false" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/10.5/phpunit.xsd" cacheDirectory=".phpunit.cache" backupStaticProperties="false">
3+
<coverage/>
84
<testsuites>
95
<testsuite name="unit">
106
<directory>tests/Unit</directory>
@@ -16,4 +12,9 @@
1612
<php>
1713

1814
</php>
15+
<source>
16+
<include>
17+
<directory suffix=".php">src/</directory>
18+
</include>
19+
</source>
1920
</phpunit>

tests/Unit/EnvironmentTest.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,12 @@ public function it_can_be_overridden()
2626
/** @test */
2727
public function precedence_is_correct()
2828
{
29-
config(['app.env' => 'app_env']);
29+
Sidecar::clearEnvironment();
30+
31+
config([
32+
'sidecar.env' => null,
33+
'app.env' => 'app_env'
34+
]);
3035

3136
$this->assertEquals('app_env', Sidecar::getEnvironment());
3237

0 commit comments

Comments
 (0)