@@ -118,7 +118,7 @@ class FileService implements IAttachmentService {
|
||||
$error = $phpFileUploadErrors[$file['error']];
|
||||
}
|
||||
if ($error !== null) {
|
||||
throw new \RuntimeException($error);
|
||||
throw new \Exception($error);
|
||||
}
|
||||
return $file;
|
||||
}
|
||||
|
||||
@@ -103,7 +103,7 @@ class FileServiceTest extends TestCase {
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \RuntimeException
|
||||
* @expectedException \Exception
|
||||
*/
|
||||
public function testCreateEmpty() {
|
||||
$attachment = $this->getAttachment();
|
||||
@@ -112,7 +112,7 @@ class FileServiceTest extends TestCase {
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \RuntimeException
|
||||
* @expectedException \Exception
|
||||
*/
|
||||
public function testCreateError() {
|
||||
$attachment = $this->getAttachment();
|
||||
|
||||
Reference in New Issue
Block a user