Browse Source

Fix tests

Jordi Boggiano 13 years ago
parent
commit
61dc13647c
1 changed files with 8 additions and 0 deletions
  1. 8 0
      tests/Composer/Test/Repository/FilesystemRepositoryTest.php

+ 8 - 0
tests/Composer/Test/Repository/FilesystemRepositoryTest.php

@@ -29,6 +29,10 @@ class FilesystemRepositoryTest extends \PHPUnit_Framework_TestCase
             ->will($this->returnValue(array(
             ->will($this->returnValue(array(
                 array('name' => 'package1', 'version' => '1.0.0-beta', 'type' => 'vendor')
                 array('name' => 'package1', 'version' => '1.0.0-beta', 'type' => 'vendor')
             )));
             )));
+        $json
+            ->expects($this->once())
+            ->method('exists')
+            ->will($this->returnValue(true));
 
 
         $packages = $repository->getPackages();
         $packages = $repository->getPackages();
 
 
@@ -48,6 +52,10 @@ class FilesystemRepositoryTest extends \PHPUnit_Framework_TestCase
             ->expects($this->once())
             ->expects($this->once())
             ->method('read')
             ->method('read')
             ->will($this->returnValue(array()));
             ->will($this->returnValue(array()));
+        $json
+            ->expects($this->once())
+            ->method('exists')
+            ->will($this->returnValue(true));
         $json
         $json
             ->expects($this->once())
             ->expects($this->once())
             ->method('write')
             ->method('write')