Skip to content

Commit 3b92399

Browse files
Simplify
1 parent d28fbcb commit 3b92399

File tree

1 file changed

+9
-12
lines changed

1 file changed

+9
-12
lines changed

tests/end-to-end/regression/3739/Issue3739Test.php

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -12,28 +12,25 @@
1212
use function unlink;
1313
use PHPUnit\Framework\TestCase;
1414

15-
class Issue3739
15+
final class Issue3739Test extends TestCase
1616
{
17-
public function unlinkFileThatDoesNotExistWithErrorSuppression(): bool
17+
public function testWithErrorSuppression(): void
1818
{
19-
return @unlink(__DIR__ . '/DOES_NOT_EXIST');
19+
$this->assertFalse($this->unlinkFileThatDoesNotExistWithErrorSuppression());
2020
}
2121

22-
public function unlinkFileThatDoesNotExistWithoutErrorSuppression(): bool
22+
public function testWithoutErrorSuppression(): void
2323
{
24-
return unlink(__DIR__ . '/DOES_NOT_EXIST');
24+
$this->assertFalse($this->unlinkFileThatDoesNotExistWithoutErrorSuppression());
2525
}
26-
}
2726

28-
final class Issue3739Test extends TestCase
29-
{
30-
public function testWithErrorSuppression(): void
27+
private function unlinkFileThatDoesNotExistWithErrorSuppression(): bool
3128
{
32-
$this->assertFalse((new Issue3739)->unlinkFileThatDoesNotExistWithErrorSuppression());
29+
return @unlink(__DIR__ . '/DOES_NOT_EXIST');
3330
}
3431

35-
public function testWithoutErrorSuppression(): void
32+
private function unlinkFileThatDoesNotExistWithoutErrorSuppression(): bool
3633
{
37-
$this->assertFalse((new Issue3739)->unlinkFileThatDoesNotExistWithoutErrorSuppression());
34+
return unlink(__DIR__ . '/DOES_NOT_EXIST');
3835
}
3936
}

0 commit comments

Comments
 (0)