aboutsummaryrefslogtreecommitdiffstats
path: root/apps/files/tests
Commit message (Collapse)AuthorAgeFilesLines
* files: Create files from template APIJulius Härtl2021-01-281-0/+10
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Add "Crop image previews" setting to filesNina Pypchenko2021-01-142-0/+15
| | | | | | | | | | | | | | Added a new user setting that toggles cropping on image previews in grid view. True (default value): crops each image to a square. False: keep original aspect ratio. Signed-off-by: Nina Pypchenko <22447785+nina-py@users.noreply.github.com> Closes #18439. Signed-off-by: npmbuildbot-nextcloud[bot] <npmbuildbot-nextcloud[bot]@users.noreply.github.com>
* Update all license headers for Nextcloud 21Christoph Wurst2020-12-166-6/+5
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Check for target folder available quota when uploadingJulius Härtl2020-11-171-0/+5
| | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net> Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Bump jquery from 2.2.4 to 3.1.0Christoph Wurst2020-11-135-225/+245
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* only run the background scanner for users that have unscanned filesRobin Appelman2020-10-201-95/+60
| | | | | | instead of looping trough all users and seeing if they have unscanned files, we do a single query to find all storages that need scanning and run trough the users for them Signed-off-by: Robin Appelman <robin@icewind.nl>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-243-0/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* merge file activity settings into a single 'favorite changed' itemRobin Appelman2020-08-131-8/+1
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to ↵Morris Jobke2020-08-123-14/+14
| | | | | | \PHPUnit\Framework\MockObject\MockObject Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Test for proper removal of mount entriesJulius Härtl2020-07-081-1/+20
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Update license headers for 19Christoph Wurst2020-04-291-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #20185 from azul/open-new_tabJohn Molakvoæ2020-04-111-30/+27
|\ | | | | Modify do_action so default ctrl-click opens tab
| * Allow opening files for editing in new tabsAzul2020-04-091-30/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In a file list files with a default action have an href that will trigger the action. This way ctrl-click and middle button click open the default action in a new tab. In order to achieve this a new param `openfile` was introduced to the files app. It will make the files app trigger the default action for the file in question. This also allows linking to file content rather than just the details display. Introduce fileList.getDefaultActionUrl() to create a link with that param set. It's overwritten in the trashbin fileList so that anchors continue to have `#` as a href. Fix the link generation for subfolders of public shares: 58a87d0 was the last commit that touched the linkTo function in public.js. It included the params as arguments to the generateUrl function. Turns out this completely ignores the dir parameter now. The inclusion was reverted in other places so revert it here as well. Also change `dir` to `path` in the param as that is respected when following the link. Add Test for the new link url for files with default action. Remove test for multiple selects with ctrl-click as that is not what we are doing anymore. Signed-off-by: Azul <azul@riseup.net>
* | Add visibility to all methods and position of static keywordChristoph Wurst2020-04-101-1/+1
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Format control structures, classes, methods and functionChristoph Wurst2020-04-109-11/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 exactly one empty line after the namespace declarationChristoph Wurst2020-04-092-2/+0
| | | | | | | | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Fix (array) indent style to always use one tabChristoph Wurst2020-04-092-16/+16
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-313-0/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Merge pull request #20170 from nextcloud/techdebt/remove-unused-importsChristoph Wurst2020-03-271-1/+0
|\ | | | | Remove unused imports
| * Remove unused importsChristoph Wurst2020-03-251-1/+0
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Use the short array syntax, everywhereChristoph Wurst2020-03-262-35/+35
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Use the shorter phpunit syntax for mocked return valuesChristoph Wurst2020-03-254-46/+46
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix unit testsJoas Schilling2020-03-101-56/+75
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Make TAG_FAVORITE publicDaniel Kesselberg2020-02-121-2/+2
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Fix license headersChristoph Wurst2020-01-131-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Fix webdav urlJohn Molakvoæ (skjnldsv)2020-01-101-1/+1
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Add pending share list to frontendJulius Härtl2020-01-071-0/+11
| | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net> Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update license headersChristoph Wurst2019-12-0510-13/+21
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Mode to modern phpunitRoeland Jago Douma2019-11-276-20/+20
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Make phpunit8 compatibleRoeland Jago Douma2019-11-277-9/+9
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Some php-cs fixesRoeland Jago Douma2019-11-225-15/+15
| | | | | | | | | | | * 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>
* fix tests for background file scan jobRobin Appelman2019-11-061-3/+18
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Adjust unit tests to new OCA.SidebarJohn Molakvoæ (skjnldsv)2019-10-291-208/+0
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Remove deprecated legacy file actionsJulius Härtl2019-10-142-92/+0
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Add new LoadAdditionalScriptsEventRoeland Jago Douma2019-09-231-1/+2
| | | | | | | This adds a new event that is in the new style of event dispatching. This should allow more lazy loading and better sepeartion of concerns Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Revert "Fix usage view tests"Daniel Kesselberg2019-07-021-1/+1
| | | | | | This reverts commit 7da7acd0 Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Fix usage view testsRoeland Jago Douma2019-07-021-1/+1
| | | | | | Follow up to #16049 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Add link icon for public link tooJohn Molakvoæ (skjnldsv)2019-03-211-2/+5
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Remove the upload and memory settingJoas Schilling2019-03-041-84/+0
| | | | | | | | | | * Remove unneeded private method phpFileSize() * Bump autoloader * Remove setUploadLimit tests * Remove integrity check hacks for upload limit Signed-off-by: Joas Schilling <coding@schilljs.com> Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add dispatcher events to User and Group objectsJoas Schilling2019-03-011-2/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fix unit testsTomasz Grobelny2019-02-201-49/+95
| | | | Signed-off-by: Tomasz Grobelny <tomasz@grobelny.net>
* Merge branch 'master' into operation_progress_improvements3Tomasz Grobelny2019-01-291-1/+2
|\ | | | | | | Signed-off-by: Tomasz Grobelny <tomasz@grobelny.net>
| * Add abort stub in JSUnitMorris Jobke2018-12-061-1/+2
| | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | Fix unit testsTomasz Grobelny2018-11-242-176/+279
|/ | | | Signed-off-by: Tomasz Grobelny <tomasz@grobelny.net>
* Rollback to default list viewJohn Molakvoæ (skjnldsv)2018-11-151-2/+2
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Enhance jsunit testsMorris Jobke2018-11-151-1/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Fix file move testsJulius Härtl2018-11-071-4/+12
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Fix testsJohn Molakvoæ (skjnldsv)2018-11-061-4/+7
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Fix move related testsTomasz Grobelny2018-11-031-54/+63
| | | | Signed-off-by: Tomasz Grobelny <tomasz@grobelny.net>
* Use grid view in other file views tooJan-Christoph Borchardt2018-10-184-4/+4
| | | | Signed-off-by: Jan-Christoph Borchardt <hey@jancborchardt.net>