]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix getMock LegacyHelperTest
authorRoeland Jago Douma <roeland@famdouma.nl>
Wed, 7 Sep 2016 18:11:43 +0000 (20:11 +0200)
committerRoeland Jago Douma <roeland@famdouma.nl>
Wed, 7 Sep 2016 18:42:38 +0000 (20:42 +0200)
tests/lib/LegacyHelperTest.php

index d8b1a82c2712e9176c7f5a30ac97cb2d70d7c4af..faea95190ecf217998a97850ebe30da2a528cb91 100644 (file)
@@ -8,6 +8,7 @@
 
 namespace Test;
 
+use OC\Files\View;
 use OC_Helper;
 
 class LegacyHelperTest extends \Test\TestCase {
@@ -129,7 +130,7 @@ class LegacyHelperTest extends \Test\TestCase {
        }
 
        function testBuildNotExistingFileNameForView() {
-               $viewMock = $this->getMock('\OC\Files\View', array(), array(), '', false);
+               $viewMock = $this->createMock(View::class);
                $this->assertEquals('/filename', OC_Helper::buildNotExistingFileNameForView('/', 'filename', $viewMock));
                $this->assertEquals('dir/filename.ext', OC_Helper::buildNotExistingFileNameForView('dir', 'filename.ext', $viewMock));