mirror of
https://codeberg.org/icewind/streams.git
synced 2026-06-03 08:34:09 +02:00
adjust tests to new phpunit
This commit is contained in:
parent
eaf1768cd9
commit
a0abe86651
9 changed files with 97 additions and 23 deletions
|
|
@ -17,10 +17,8 @@ class NullWrapperTest extends WrapperTest {
|
|||
return \Icewind\Streams\NullWrapper::wrap($source);
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \BadMethodCallException
|
||||
*/
|
||||
public function testNoContext() {
|
||||
$this->expectException(\BadMethodCallException::class);
|
||||
stream_wrapper_register('null', '\Icewind\Streams\NullWrapper');
|
||||
$context = stream_context_create(array());
|
||||
try {
|
||||
|
|
@ -32,10 +30,8 @@ class NullWrapperTest extends WrapperTest {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \BadMethodCallException
|
||||
*/
|
||||
public function testNoSource() {
|
||||
$this->expectException(\BadMethodCallException::class);
|
||||
stream_wrapper_register('null', '\Icewind\Streams\NullWrapper');
|
||||
$context = stream_context_create(array(
|
||||
'null' => array(
|
||||
|
|
@ -50,10 +46,8 @@ class NullWrapperTest extends WrapperTest {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \BadMethodCallException
|
||||
*/
|
||||
public function testWrapInvalidSource() {
|
||||
$this->expectException(\BadMethodCallException::class);
|
||||
$this->wrapSource('foo');
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue