Update test

This commit is contained in:
Pig Fang 2018-07-23 10:11:04 +08:00
parent 35832a6993
commit c3934702e0

View File

@ -14,7 +14,7 @@ class PluginControllerTest extends TestCase
$plugins = [
'example-plugin' => 'example-plugin_v1.0.0.zip',
'avatar-api' => 'avatar-api_v1.1.0.zip'
'avatar-api' => 'avatar-api_v1.1.1.zip'
];
foreach ($plugins as $plugin_name => $filename) {
@ -81,6 +81,16 @@ class PluginControllerTest extends TestCase
'msg' => trans('admin.invalid-action')
]);
// Retrieve requirements
$this->postJson('/admin/plugins/manage', [
'name' => 'avatar-api',
'action' => 'requirements'
])->assertJson([
'isRequirementsSatisfied' => true,
'requirements' => [],
'unsatisfiedRequirements' => []
]);
// Enable a plugin with unsatisfied dependencies
app('plugins')->getPlugin('avatar-api')->setRequirements([
'blessing-skin-server' => '^3.4.0',