浏览代码

[tests] update support for the latest doctrine2 orm and odm versions

gedi 13 年之前
父节点
当前提交
3d6c85ad9a
共有 3 个文件被更改,包括 30 次插入14 次删除
  1. 10 10
      bin/vendors.php
  2. 10 2
      tests/Gedmo/Tool/BaseTestCaseMongoODM.php
  3. 10 2
      tests/Gedmo/Tool/BaseTestCaseOM.php

+ 10 - 10
bin/vendors.php

@@ -34,16 +34,16 @@ $deps22x = array(
     array('Symfony/Component/Yaml', 'http://github.com/symfony/Yaml.git', 'v2.0.7'),
 );
 $deps23x = array(
-    array('doctrine-orm', 'http://github.com/doctrine/doctrine2.git', '35fc3c0671'),
-    array('doctrine-dbal', 'http://github.com/doctrine/dbal.git', 'ef6c86fef3'),
-    array('doctrine-common', 'http://github.com/doctrine/common.git', '38c854c37d'),
-    array('doctrine-mongodb', 'http://github.com/doctrine/mongodb.git', '01babdde34'),
-    array('doctrine-mongodb-odm', 'http://github.com/doctrine/mongodb-odm.git', 'fb2447c01c'),
-
-    array('Symfony/Component/ClassLoader', 'http://github.com/symfony/ClassLoader.git', 'v2.0.9'),
-    array('Symfony/Component/Console', 'http://github.com/symfony/Console.git', 'v2.0.9'),
-    array('Symfony/Component/Finder', 'http://github.com/symfony/Finder.git', 'v2.0.9'),
-    array('Symfony/Component/Yaml', 'http://github.com/symfony/Yaml.git', 'v2.0.9'),
+    array('doctrine-orm', 'http://github.com/doctrine/doctrine2.git', '6cd82d77f5'),
+    array('doctrine-dbal', 'http://github.com/doctrine/dbal.git', 'c8835edf74'),
+    array('doctrine-common', 'http://github.com/doctrine/common.git', 'fc26d10d97'),
+    array('doctrine-mongodb', 'http://github.com/doctrine/mongodb.git', 'd7fdcff25b'),
+    array('doctrine-mongodb-odm', 'http://github.com/doctrine/mongodb-odm.git', 'e8c0bfb975'),
+
+    array('Symfony/Component/ClassLoader', 'http://github.com/symfony/ClassLoader.git', 'v2.1.0'),
+    array('Symfony/Component/Console', 'http://github.com/symfony/Console.git', 'v2.1.0'),
+    array('Symfony/Component/Finder', 'http://github.com/symfony/Finder.git', 'v2.1.0'),
+    array('Symfony/Component/Yaml', 'http://github.com/symfony/Yaml.git', 'v2.1.0'),
 );
 
 foreach ($deps23x as $dep) {

+ 10 - 2
tests/Gedmo/Tool/BaseTestCaseMongoODM.php

@@ -158,9 +158,17 @@ abstract class BaseTestCaseMongoODM extends \PHPUnit_Framework_TestCase
             ->method('getClassMetadataFactoryName')
             ->will($this->returnValue('Doctrine\\ODM\\MongoDB\\Mapping\\ClassMetadataFactory'));
 
-        $config->expects($this->any())
+        $config
+            ->expects($this->any())
             ->method('getMongoCmd')
-            ->will($this->returnValue('$'));
+            ->will($this->returnValue('$'))
+        ;
+
+        $config
+            ->expects($this->any())
+            ->method('getDefaultCommitOptions')
+            ->will($this->returnValue(array('safe' => true)))
+        ;
 
         $mappingDriver = $this->getMetadataDriverImplementation();
 

+ 10 - 2
tests/Gedmo/Tool/BaseTestCaseOM.php

@@ -249,9 +249,17 @@ abstract class BaseTestCaseOM extends \PHPUnit_Framework_TestCase
             ->method('getClassMetadataFactoryName')
             ->will($this->returnValue('Doctrine\\ODM\\MongoDB\\Mapping\\ClassMetadataFactory'));
 
-        $config->expects($this->any())
+        $config
+            ->expects($this->any())
             ->method('getMongoCmd')
-            ->will($this->returnValue('$'));
+            ->will($this->returnValue('$'))
+        ;
+
+        $config
+            ->expects($this->any())
+            ->method('getDefaultCommitOptions')
+            ->will($this->returnValue(array('safe' => true)))
+        ;
 
         if (is_null($mappingDriver)) {
             $mappingDriver = $this->getDefaultMongoODMMetadataDriverImplementation();