Esempio n. 1
0
 public function testContentTypeAuto()
 {
     $expectedData = 'default_media_type; charset=default_charset';
     $this->model->setContentType('auto');
     $this->scopeConfig->expects($this->at(0))->method('getValue')->with('design/head/default_media_type', 'store')->will($this->returnValue('default_media_type'));
     $this->scopeConfig->expects($this->at(1))->method('getValue')->with('design/head/default_charset', 'store')->will($this->returnValue('default_charset'));
     $this->assertEquals($expectedData, $this->model->getContentType());
 }
 /**
  * {@inheritdoc}
  */
 public function setContentType($contentType)
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'setContentType');
     if (!$pluginInfo) {
         return parent::setContentType($contentType);
     } else {
         return $this->___callPlugins('setContentType', func_get_args(), $pluginInfo);
     }
 }
Esempio n. 3
0
 public function testContentType()
 {
     $contentType = 'test_content_type';
     $this->model->setContentType($contentType);
     $this->assertEquals($contentType, $this->model->getContentType());
 }