diff --git a/tests/Polyfills/AssertIsTypeTest.php b/tests/Polyfills/AssertIsTypeTest.php index 902f7f8..00c3c23 100644 --- a/tests/Polyfills/AssertIsTypeTest.php +++ b/tests/Polyfills/AssertIsTypeTest.php @@ -82,6 +82,18 @@ public function testAssertIsResource() { \closedir( $resource ); } + /** + * Verify assertIsResource() method handles closed resources correctly. + * + * @return void + */ + public function testAssertIsResourceAllowsForClosedResources() { + $resource = \opendir( __DIR__ ); + \closedir( $resource ); + + $this->assertIsResource( $resource ); + } + /** * Verify availability of the assertIsArray() method. *