|
@@ 27-39 (lines=13) @@
|
| 24 |
|
* @expectedException \Symfony\Component\Config\Definition\Exception\InvalidConfigurationException |
| 25 |
|
* @expectedExceptionMessage Page class must be a valid class extending Orbitale\Bundle\CmsBundle\Entity\Page. "inexistent_page_class" given. |
| 26 |
|
*/ |
| 27 |
|
public function testInexistentPageClass() |
| 28 |
|
{ |
| 29 |
|
$builder = new ContainerBuilder(); |
| 30 |
|
|
| 31 |
|
$ext = new OrbitaleCmsExtension(); |
| 32 |
|
|
| 33 |
|
$ext->load([ |
| 34 |
|
'orbitale_cms' => [ |
| 35 |
|
'page_class' => 'inexistent_page_class', |
| 36 |
|
'category_class' => Category::class, |
| 37 |
|
], |
| 38 |
|
], $builder); |
| 39 |
|
} |
| 40 |
|
|
| 41 |
|
/** |
| 42 |
|
* @expectedException \Symfony\Component\Config\Definition\Exception\InvalidConfigurationException |
|
@@ 45-57 (lines=13) @@
|
| 42 |
|
* @expectedException \Symfony\Component\Config\Definition\Exception\InvalidConfigurationException |
| 43 |
|
* @expectedExceptionMessage Category class must be a valid class extending Orbitale\Bundle\CmsBundle\Entity\Category. "inexistent_category_class" given. |
| 44 |
|
*/ |
| 45 |
|
public function testInexistentCategoryClass() |
| 46 |
|
{ |
| 47 |
|
$builder = new ContainerBuilder(); |
| 48 |
|
|
| 49 |
|
$ext = new OrbitaleCmsExtension(); |
| 50 |
|
|
| 51 |
|
$ext->load([ |
| 52 |
|
'orbitale_cms' => [ |
| 53 |
|
'page_class' => Page::class, |
| 54 |
|
'category_class' => 'inexistent_category_class', |
| 55 |
|
], |
| 56 |
|
], $builder); |
| 57 |
|
} |
| 58 |
|
|
| 59 |
|
/** |
| 60 |
|
* @dataProvider provideYamlConfiguration |