Clean up
This commit is contained in:
parent
17c267ea55
commit
7021ef49b4
|
|
@ -12,23 +12,8 @@ use Illuminate\Filesystem\Filesystem;
|
||||||
|
|
||||||
class PluginManagerTest extends TestCase
|
class PluginManagerTest extends TestCase
|
||||||
{
|
{
|
||||||
public function rebootPluginManager(PluginManager $manager)
|
|
||||||
{
|
|
||||||
$reflection = new ReflectionClass($manager);
|
|
||||||
$property = $reflection->getProperty('booted');
|
|
||||||
$property->setAccessible(true);
|
|
||||||
$property->setValue($manager, false);
|
|
||||||
|
|
||||||
$manager->boot();
|
|
||||||
|
|
||||||
return $manager;
|
|
||||||
}
|
|
||||||
|
|
||||||
public function testPreventBootingAgain()
|
public function testPreventBootingAgain()
|
||||||
{
|
{
|
||||||
$this->mock(Option::class, function ($mock) {
|
|
||||||
$mock->shouldReceive('get')->with('plugins_enabled', '[]')->andReturn('[]');
|
|
||||||
});
|
|
||||||
$this->mock(Filesystem::class, function ($mock) {
|
$this->mock(Filesystem::class, function ($mock) {
|
||||||
$mock->shouldReceive('directories')->times(0);
|
$mock->shouldReceive('directories')->times(0);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user