aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Files/ViewTest.php
Commit message (Collapse)AuthorAgeFilesLines
* Remove unused method getLocalFolderCôme Chilliet2023-04-031-1/+0
| | | | | | It’s not used and not in any OCP interface/class. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Tidy up typing in OC\Files\ViewCôme Chilliet2023-04-031-1/+1
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Merge pull request #36566 from nextcloud/mount-find-by-numeric-idJulius Härtl2023-02-081-0/+3
|\
| * fix testsRobin Appelman2023-02-071-0/+3
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Fix filesize return type error in ViewTestCôme Chilliet2023-02-071-4/+16
|/ | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* add test for trying to fopen a file which no longer exists on diskRobin Appelman2022-09-291-0/+19
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Move CappedMemoryCache to OCPCarl Schwan2022-07-141-1/+1
| | | | | | | | This is an helpful helper that should be used in more place than just server and this is already the case with groupfodlers, deck, user_oidc and more using it, so let's make it public Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Remove some more at matchers in tests/libCôme Chilliet2022-06-201-34/+21
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* adjust tests to new fs setupRobin Appelman2022-03-041-4/+12
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Fix PHP deprecation warning in File/ViewTestCôme Chilliet2021-12-161-1/+4
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Properly handle result when copying with failure and throw in testsJulius Härtl2021-01-051-1/+2
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Fix writeStream mockingJulius Härtl2021-01-051-1/+1
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Replace static call to Share::unshare with ShareManager->deleteShare in testsMorris Jobke2020-11-301-1/+3
| | | | | | And then cleanup all the code that is dead then... Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to ↵Morris Jobke2020-08-121-13/+13
| | | | | | \PHPUnit\Framework\MockObject\MockObject Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* use exceptions for error signaling in writeStreamRobin Appelman2020-07-231-1/+0
| | | | | | this remove the ambiguity when writing zero length files Signed-off-by: Robin Appelman <robin@icewind.nl>
* rollback cache rename if trashbin move failsRobin Appelman2020-07-231-7/+2
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Update share type constant usageJoas Schilling2020-06-241-5/+5
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-101-3/+0
| | | | | | | | | | | | | | | To continue this formatting madness, here's a tiny patch that adds unified formatting for control structures like if and loops as well as classes, their methods and anonymous functions. This basically forces the constructs to start on the same line. This is not exactly what PSR2 wants, but I think we can have a few exceptions with "our" style. The starting of braces on the same line is pracrically standard for our code. This also removes and empty lines from method/function bodies at the beginning and end. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use elseif instead of else ifChristoph Wurst2020-04-101-1/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* fix testsRobin Appelman2020-04-011-6/+26
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Use the shorter phpunit syntax for mocked return valuesChristoph Wurst2020-03-251-28/+28
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Mode to modern phpunitRoeland Jago Douma2019-11-271-13/+19
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Make phpunit8 compatibleRoeland Jago Douma2019-11-271-2/+2
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Files first to use own GenericEventArthur Schiwon2019-11-261-1/+0
| | | | | | * those are added to 18 only anyway :) Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Some php-cs fixesRoeland Jago Douma2019-11-221-2/+2
| | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* expose filecache extension data in FileInfoRobin Appelman2019-11-131-213/+236
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix testsRobin Appelman2019-06-211-0/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* cleanup shared lock if changing to exclusive lock failedRobin Appelman2019-01-221-0/+31
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Moves the logo files to logoMichael Weimann2018-10-021-2/+2
| | | | Signed-off-by: Michael Weimann <mail@michael-weimann.eu>
* Fix ViewTestRoeland Jago Douma2018-05-231-1/+11
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Remove IAppConfig::getValueRoeland Jago Douma2018-01-171-7/+7
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Use ::class in test mocks of dav appMorris Jobke2017-10-261-2/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Cleanup unused methodsMorris Jobke2017-08-151-1/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Cleanup usage of shareItem in internal code baseMorris Jobke2017-08-151-1/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Replace wrong PHPDocsLukas Reschke2017-08-011-2/+3
| | | | Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* round the mtime in touchRobin Appelman2017-03-271-0/+17
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Move error message to log entryLukas Reschke2017-03-201-0/+2
| | | | Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* Cleanup testJoas Schilling2017-03-171-254/+266
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fix unit testJoas Schilling2017-03-171-2/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Redirect unlink to rmdir (#27101)Vincent Petry2017-03-161-0/+24
| | | | | | | Many API callers will call unlink even for directories and it can mess up with some wrappers like the encryption wrapper Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add testsLukas Reschke2016-12-011-0/+71
| | | | Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* only query substorages to calculate the final mtime/size/etag lazilyRobin Appelman2016-11-101-1/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Fix getMock ViewTestRoeland Jago Douma2016-09-131-6/+7
|
* Remove unneeded checks if it runs on a Windows machineMorris Jobke2016-07-081-6/+2
| | | | * the setup check is still there
* Fix unit testsRoeland Jago Douma2016-06-141-0/+7
|
* allow deleting "ghost files" trough the View and Node apiRobin Appelman2016-06-031-1/+50
|
* Move tests/ to PSR-4 (#24731)Joas Schilling2016-05-201-0/+2447
* Move a-b to PSR-4 * Move c-d to PSR-4 * Move e+g to PSR-4 * Move h-l to PSR-4 * Move m-r to PSR-4 * Move s-u to PSR-4 * Move files/ to PSR-4 * Move remaining tests to PSR-4 * Remove Test\ from old autoloader