formatting

This commit is contained in:
Robin Appelman 2021-03-02 19:25:43 +01:00
commit fdc0e3f113
21 changed files with 118 additions and 111 deletions

View file

@ -18,9 +18,9 @@ class NullWrapperTest extends WrapperTest {
}
public function testNoContext() {
$this->expectException(\BadMethodCallException::class);
$this->expectException(\BadMethodCallException::class);
stream_wrapper_register('null', '\Icewind\Streams\NullWrapper');
$context = stream_context_create(array());
$context = stream_context_create([]);
try {
fopen('null://', 'r+', false, $context);
stream_wrapper_unregister('null');
@ -31,13 +31,13 @@ class NullWrapperTest extends WrapperTest {
}
public function testNoSource() {
$this->expectException(\BadMethodCallException::class);
$this->expectException(\BadMethodCallException::class);
stream_wrapper_register('null', '\Icewind\Streams\NullWrapper');
$context = stream_context_create(array(
'null' => array(
$context = stream_context_create([
'null' => [
'source' => 'bar'
)
));
]
]);
try {
fopen('null://', 'r+', false, $context);
} catch (\Exception $e) {
@ -47,7 +47,7 @@ class NullWrapperTest extends WrapperTest {
}
public function testWrapInvalidSource() {
$this->expectException(\BadMethodCallException::class);
$this->expectException(\BadMethodCallException::class);
$this->wrapSource('foo');
}
}