Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

Commit 9f8213b

Browse files
committed
add schema test
1 parent c803f69 commit 9f8213b

File tree

5 files changed

+39
-1
lines changed

5 files changed

+39
-1
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,4 @@ vendor
22
composer.lock
33
composer.phar
44
Tests/Resources/app/cache
5+
Tests/Resources/app/logs
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<config xmlns="http://cmf.symfony.com/schema/dic/treebrowser">
2+
</config>
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
<config xmlns="http://cmf.symfony.com/schema/dic/treebrowser">
2+
<persistence>
3+
<phpcr
4+
session-name="default"
5+
/>
6+
</persistence>
7+
</config>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?php
2+
/*
3+
* This file is part of the Symfony CMF package.
4+
*
5+
* (c) 2011-2013 Symfony CMF
6+
*
7+
* For the full copyright and license information, please view the LICENSE
8+
* file that was distributed with this source code.
9+
*/
10+
11+
namespace Symfony\Cmf\Bundle\TreeBrowserBundle\Tests\Unit\DependencyInjection;
12+
13+
use Symfony\Cmf\Component\Testing\Unit\XmlSchemaTestCase;
14+
15+
class XmlSchemaTest extends XmlSchemaTestCase
16+
{
17+
public function testSchema()
18+
{
19+
$xmlFiles = array_map(function ($file) {
20+
return __DIR__.'/../../Resources/Fixtures/config/'.$file;
21+
}, array(
22+
'config1.xml',
23+
'config2.xml',
24+
));
25+
26+
$this->assertSchemaAcceptsXml($xmlFiles, __DIR__.'/../../../Resources/config/schema/treebrowser-1.0.xsd');
27+
}
28+
}

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"friendsofsymfony/jsrouting-bundle": "~1.1"
1919
},
2020
"require-dev": {
21-
"symfony-cmf/testing": "1.0.*"
21+
"symfony-cmf/testing": "1.1.*"
2222
},
2323
"suggest": {
2424
"doctrine/phpcr-bundle": "1.0.*",

0 commit comments

Comments
 (0)