Skip to content

Commit a53440d

Browse files
committed
refactor: use ReflectionMethod for isolated testing
1 parent 5e46018 commit a53440d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/Tempest/Storage/src/GenericStorage.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
use League\Flysystem\FilesystemAdapter;
88
use League\Flysystem\ReadOnly\ReadOnlyFilesystemAdapter;
99
use League\Flysystem\UrlGeneration\TemporaryUrlGenerator;
10+
use ReflectionMethod;
1011
use Tempest\Reflection\MethodReflector;
1112
use Tempest\Storage\Config\StorageConfig;
1213

@@ -155,7 +156,7 @@ public function list(string $location = '', bool $deep = false): DirectoryListin
155156
private function createAdapter(): FilesystemAdapter
156157
{
157158
$this->assertAdapterInstalled(
158-
MethodReflector::fromParts($this->storageConfig, 'createAdapter')->getReturnType()->getName(),
159+
new ReflectionMethod($this->storageConfig, 'createAdapter')->getReturnType()->getName(),
159160
);
160161

161162
$adapter = $this->storageConfig->createAdapter();

0 commit comments

Comments
 (0)