]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix 2 assertions
authorJoas Schilling <nickvergessen@gmx.de>
Thu, 29 Jan 2015 15:09:35 +0000 (16:09 +0100)
committerJoas Schilling <nickvergessen@gmx.de>
Thu, 29 Jan 2015 15:09:35 +0000 (16:09 +0100)
apps/files_encryption/tests/share.php

index 5632607319b08b95d555a51ed2f94a4da48bc1f3..44fd2ac9c7c85c32e91064019bd9cbf41805c354 100755 (executable)
@@ -218,7 +218,7 @@ class Share extends TestCase {
                $cryptedFile = file_put_contents('crypt:///' . self::TEST_ENCRYPTION_SHARE_USER1 . '/files/' . $this->filename, $this->dataShort);
 
                // test that data was successfully written
-               $this->assertTrue(is_int($cryptedFile));
+               $this->assertInternalType('int', $cryptedFile);
 
                // disable encryption proxy to prevent recursive calls
                $proxyStatus = \OC_FileProxy::$enabled;
@@ -229,7 +229,7 @@ class Share extends TestCase {
                        '/' . self::TEST_ENCRYPTION_SHARE_USER1 . '/files/' . $this->filename);
 
                // check if we have a valid file info
-               $this->assertTrue($fileInfo instanceof \OC\Files\FileInfo);
+               $this->assertInstanceOf('\\OC\\Files\\FileInfo', $fileInfo);
 
                // check if the unencrypted file size is stored
                $this->assertGreaterThan(0, $fileInfo['unencrypted_size']);
@@ -1384,4 +1384,4 @@ class Share extends TestCase {
                \OC\Files\Filesystem::unlink($folder);
        }
 
-}
\ No newline at end of file
+}