コード例 #1
0
ファイル: ProcessTest.php プロジェクト: ysaroka/autothumb
 /**
  * @expectedException        \ysaroka\autothumb\exception\ProcessException
  * @expectedExceptionMessageRegExp /image file extension "[\w\d]+" not allowed for processing/i
  */
 public function testProcessExceptionAllowedExtensions()
 {
     $this->config['allowed_extensions'] = ['other-ext'];
     $this->autoThumb->setConfig($this->config);
     $this->autoThumb->process($this->variables, false);
 }
コード例 #2
0
ファイル: AutoThumbTest.php プロジェクト: ysaroka/autothumb
 /**
  * @expectedException        \ysaroka\autothumb\exception\ConfigurationException
  * @expectedExceptionMessageRegExp /Image file "watermark": .* for type "small" does not exist/i
  */
 public function testSetConfigExceptionInvalidWatemarkPath()
 {
     $this->config['types'] = ['small' => ['watermark' => TEST_DIR . 'data/images/watermarks/invalid/path/watermark-invalid.png']];
     $this->autoThumb->setConfig($this->config);
 }