This commit is contained in:
Pig Fang 2019-08-12 09:56:51 +08:00
parent b7ee522d86
commit 197b61b9d6
2 changed files with 7 additions and 7 deletions

View File

@ -11,7 +11,7 @@ DB_HOST = 127.0.0.1
DB_PORT = 3306
DB_DATABASE = test
DB_USERNAME = root
DB_PASSWORD = null
DB_PASSWORD = root
DB_PREFIX = null
PWD_METHOD = BCRYPT
@ -34,7 +34,7 @@ REDIS_HOST = 127.0.0.1
REDIS_PASSWORD = null
REDIS_PORT = 6379
PLUGINS_DIR = plugins
PLUGINS_DIR = null
PLUGINS_URL = null
JWT_SECRET = 1tdM3gXarxYI4KlAHMBo238iC2tEb4I3EtBlZTQQXvInXIt7V2ix7hJ1KTvxCKZW

View File

@ -33,17 +33,17 @@ class PluginManagerTest extends TestCase
{
$this->mock(Filesystem::class, function ($mock) {
$mock->shouldReceive('directories')
->with(config('plugins.directory'))
->with(base_path('plugins'))
->once()
->andReturn(collect(['/nano', '/yuko']));
$mock->shouldReceive('exists')
->with('/nano/package.json')
->with('/nano'.DIRECTORY_SEPARATOR.'package.json')
->once()
->andReturn(true);
$mock->shouldReceive('get')
->with('/nano/package.json')
->with('/nano'.DIRECTORY_SEPARATOR.'package.json')
->once()
->andReturn(json_encode([
'name' => 'fake',
@ -51,12 +51,12 @@ class PluginManagerTest extends TestCase
]));
$mock->shouldReceive('exists')
->with('/yuko/package.json')
->with('/yuko'.DIRECTORY_SEPARATOR.'package.json')
->once()
->andReturn(true);
$mock->shouldReceive('get')
->with('/yuko/package.json')
->with('/yuko'.DIRECTORY_SEPARATOR.'package.json')
->once()
->andReturn(json_encode([
'name' => 'fake',