1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-12 20:02:08 +02:00

[ticket/15037]a attempt to fix stupid test issue

PHPBB3-15037
This commit is contained in:
hanakin 2017-01-23 21:59:00 -05:00
parent 71ca228b8e
commit 3e73413982
2 changed files with 3 additions and 3 deletions

BIN
phpBB/develop/test.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 807 B

View File

@ -101,7 +101,7 @@ class phpbb_functional_fileupload_remote_test extends phpbb_functional_test_case
$upload->set_error_prefix('')
->set_allowed_extensions(array('gif'))
->set_max_filesize(1000);
$file = $upload->handle_upload('files.types.remote', self::$root_url . 'styles/prosilver/theme/images/forum_read.gif');
$file = $upload->handle_upload('files.types.remote', self::$root_url . 'develop/test.gif');
$this->assertEquals(0, sizeof($file->error));
$this->assertTrue(file_exists($file->get('filename')));
$this->assertTrue($file->is_uploaded());
@ -113,8 +113,8 @@ class phpbb_functional_fileupload_remote_test extends phpbb_functional_test_case
$upload = new \phpbb\files\upload($this->filesystem, $this->factory, $this->language, $this->php_ini, $this->request, $this->phpbb_root_path);
$upload->set_error_prefix('')
->set_allowed_extensions(array('gif'))
->set_max_filesize(100);
$file = $upload->handle_upload('files.types.remote', self::$root_url . 'styles/prosilver/theme/images/forum_read.gif');
->set_max_filesize(1);
$file = $upload->handle_upload('files.types.remote', self::$root_url . 'develop/test.gif');
$this->assertEquals(1, sizeof($file->error));
$this->assertEquals('WRONG_FILESIZE', $file->error[0]);
}