mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-05 16:27:38 +02:00
Merge pull request #6664 from rubencm/ticket/17357
[ticket/17357] Remove file_info from storage
This commit is contained in:
@@ -86,16 +86,16 @@ class phpbb_attachment_delete_test extends \phpbb_database_test_case
|
||||
public function data_attachment_unlink()
|
||||
{
|
||||
return array(
|
||||
array(true, true, true),
|
||||
array(true, false, false),
|
||||
array(true, true, false, true),
|
||||
array(true, true),
|
||||
array(false, false),
|
||||
array(true, false, true),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider data_attachment_unlink
|
||||
*/
|
||||
public function test_attachment_delete_success($remove_success, $exists_success, $expected, $throw_exception = false)
|
||||
public function test_attachment_delete_success($exists_success, $expected, $throw_exception = false)
|
||||
{
|
||||
$this->storage = $this->createMock('\phpbb\storage\storage');
|
||||
if ($throw_exception)
|
||||
@@ -107,8 +107,7 @@ class phpbb_attachment_delete_test extends \phpbb_database_test_case
|
||||
else
|
||||
{
|
||||
$this->storage->expects($this->any())
|
||||
->method('delete')
|
||||
->willReturn($remove_success);
|
||||
->method('delete');
|
||||
}
|
||||
$this->storage->expects($this->any())
|
||||
->method('exists')
|
||||
|
@@ -33,8 +33,6 @@ class phpbb_local_test_case extends phpbb_test_case
|
||||
|
||||
$this->adapter = new local(
|
||||
$this->filesystem,
|
||||
new FastImageSize(),
|
||||
new guesser(array(new extension_guesser)),
|
||||
$phpbb_root_path
|
||||
);
|
||||
|
||||
|
Reference in New Issue
Block a user