Fix mock object to return proper type

This commit is contained in:
Thomas Müller 2015-04-09 17:45:57 +02:00
parent ec69f2838c
commit 11c3741526

View file

@ -29,7 +29,9 @@ class Encryption extends \Test\TestCase {
->getMock();
$file = $this->getMockBuilder('\OC\Encryption\File')
->disableOriginalConstructor()
->setMethods(['getAccessList'])
->getMock();
$file->expects($this->any())->method('getAccessList')->willReturn([]);
$util = $this->getMock('\OC\Encryption\Util', ['getUidAndFilename'], [new View(), new \OC\User\Manager(), $config]);
$util->expects($this->any())
->method('getUidAndFilename')