Skip to content

Commit

Permalink
Make XML config fixtures consistent
Browse files Browse the repository at this point in the history
  • Loading branch information
jmikola committed May 16, 2014
1 parent 9eaaeed commit aff3828
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 38 deletions.
66 changes: 34 additions & 32 deletions Tests/DependencyInjection/Fixtures/config/xml/full.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:doctrine_mongodb="http://symfony.com/schema/dic/doctrine/odm/mongodb"
xmlns:doctrine="http://symfony.com/schema/dic/doctrine/odm/mongodb"
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd
http://symfony.com/schema/dic/doctrine/odm/mongodb http://symfony.com/schema/dic/doctrine/odm/mongodb/mongodb-1.0.xsd">

<doctrine_mongodb:config
<doctrine:config
auto-generate-hydrator-classes="true"
auto-generate-proxy-classes="true"
default-connection="conn1"
Expand All @@ -18,7 +18,7 @@
proxy-namespace="Test_Proxies"
>

<doctrine_mongodb:default-commit-options
<doctrine:default-commit-options
j="false"
timeout="10"
w="majority"
Expand All @@ -27,8 +27,8 @@
safe="2"
/>

<doctrine_mongodb:connection id="conn1" server="mongodb://localhost">
<doctrine_mongodb:options
<doctrine:connection id="conn1" server="mongodb://localhost">
<doctrine:options
connect="true"
connectTimeoutMS="500"
db="database_val"
Expand All @@ -43,46 +43,48 @@
w="majority"
wTimeoutMS="1000"
>
<doctrine_mongodb:readPreferenceTags>
<doctrine_mongodb:readPreferenceTag name="dc" value="east" />
<doctrine_mongodb:readPreferenceTag name="use" value="reporting" />
</doctrine_mongodb:readPreferenceTags>
<doctrine_mongodb:readPreferenceTags>
<doctrine_mongodb:readPreferenceTag name="dc" value="west" />
</doctrine_mongodb:readPreferenceTags>
<doctrine_mongodb:readPreferenceTags />
</doctrine_mongodb:options>
</doctrine_mongodb:connection>
<doctrine:readPreferenceTags>
<doctrine:readPreferenceTag name="dc" value="east" />
<doctrine:readPreferenceTag name="use" value="reporting" />
</doctrine:readPreferenceTags>
<doctrine:readPreferenceTags>
<doctrine:readPreferenceTag name="dc" value="west" />
</doctrine:readPreferenceTags>
<doctrine:readPreferenceTags />
</doctrine:options>
</doctrine:connection>

<doctrine_mongodb:connection id="conn2" server="mongodb://otherhost" />
<doctrine:connection id="conn2" server="mongodb://otherhost" />

<doctrine_mongodb:document-manager id="dm1">
<doctrine_mongodb:mapping name="FooBundle" type="annotation" />
<doctrine_mongodb:metadata-cache-driver type="memcache">
<doctrine_mongodb:class>fooClass</doctrine_mongodb:class>
<doctrine_mongodb:host>host_val</doctrine_mongodb:host>
<doctrine_mongodb:port>1234</doctrine_mongodb:port>
<doctrine_mongodb:instance-class>instance_val</doctrine_mongodb:instance-class>
</doctrine_mongodb:metadata-cache-driver>
<doctrine_mongodb:profiler enabled="true" pretty="false" />
<doctrine_mongodb:filter name="test_filter" enabled="true" class="TestClass" />
</doctrine_mongodb:document-manager>
<doctrine:document-manager id="dm1">
<doctrine:mapping name="FooBundle" type="annotation" />
<doctrine:metadata-cache-driver type="memcache">
<doctrine:class>fooClass</doctrine:class>
<doctrine:host>host_val</doctrine:host>
<doctrine:port>1234</doctrine:port>
<doctrine:instance-class>instance_val</doctrine:instance-class>
</doctrine:metadata-cache-driver>
<doctrine:profiler enabled="true" pretty="false" />
<doctrine:filter name="test_filter" enabled="true" class="TestClass" />
</doctrine:document-manager>

<doctrine_mongodb:document-manager
<doctrine:document-manager
id="dm2"
connection="dm2_connection"
database="db1"
metadata-cache-driver="apc"
logging="true"
>
<doctrine_mongodb:mapping
<doctrine:mapping
name="BarBundle"
type="yml"
dir="%kernel.cache_dir%"
prefix="prefix_val"
alias="alias_val"
is-bundle="false"
/>
</doctrine_mongodb:document-manager>
</doctrine_mongodb:config>
</container>
</doctrine:document-manager>

<doctrine:resolve-target-document interface="Foo\BarInterface">Bar\FooClass</doctrine:resolve-target-document>
</doctrine:config>
</container>
Original file line number Diff line number Diff line change
Expand Up @@ -23,4 +23,4 @@
<doctrine:document-manager id="dm1" metadata-cache-driver="xcache" connection="conn1" />
<doctrine:document-manager id="dm2" connection="conn2" metadata-cache-driver="apc" />
</doctrine:mongodb>
</container>
</container>
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@
</doctrine:metadata-cache-driver>
</doctrine:document-manager>
</doctrine:mongodb>
</container>
</container>
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@
</doctrine:document-manager>

</doctrine:mongodb>
</container>
</container>
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<?xml version="1.0" ?>

<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:doctrine="http://symfony.com/schema/dic/doctrine/odm/mongodb"
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:doctrine="http://symfony.com/schema/dic/doctrine/odm/mongodb"
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd
http://symfony.com/schema/dic/doctrine/odm/mongodb http://symfony.com/schema/dic/doctrine/odm/mongodb/mongodb-1.0.xsd">

<doctrine:config>
Expand Down

0 comments on commit aff3828

Please sign in to comment.