aboutsummaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #48721 from nextcloud/feat/allow-getter-setter-decl-forsJohn Molakvoæ2024-11-061-0/+76
|\
| * feat(DeclarativeSettings): Allow to implement value getter and setter ↵Ferdinand Thiessen2024-10-151-0/+76
| | | | | | | | | | | | | | | | | | directly in Form Instead of implementing the form class, a setter event listener and a getter event listener, this allows to simply write a basic class that provides `getSchema`, `setValue` and `getValue` functions. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | fix: Handle exception when clearing previously removed two factor tokensclear-pending-two-factor-tokens-also-from-configurationDaniel Calviño Sánchez2024-11-051-0/+32
| | | | | | | | | | | | | | | | If a token was already removed from the database but not from the configuration clearing the tokens will try to remove it again from the database, which caused a DoesNotExistException to be thrown. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* | fix: Clear pending two factor tokens also from configurationDaniel Calviño Sánchez2024-11-051-0/+26
| | | | | | | | | | | | | | | | | | Otherwise as the tokens were removed from the database but not from the configuration the next time that the tokens were cleared the previous tokens were still got from the configuration, and trying to remove them again from the database ended in a DoesNotExistException being thrown. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* | Merge pull request #47425 from ↵Côme Chilliet2024-11-041-3/+187
|\ \ | | | | | | | | | | | | nextcloud/fix/avoid-invalid-share-on-transfer-ownership fix: promote re-shares when deleting the parent share
| * | fix: Use getRelativePath method to check if node is inside folderfix/avoid-invalid-share-on-transfer-ownershipCôme Chilliet2024-10-141-10/+14
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
| * | fix: Fix promotion of reshares from subsubfoldersCôme Chilliet2024-10-141-16/+84
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
| * | fix(tests): Fix share tests to test new reshare promotion systemCôme Chilliet2024-10-141-17/+17
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
| * | fix: Tidy up code for reshare deletionCôme Chilliet2024-10-141-8/+8
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
| * | fix: delete re-shares when deleting the parent shareLuka Trovic2024-10-141-3/+115
| | | | | | | | | | | | | | | | | | | | | Note: Removed part about fix command from original PR Signed-off-by: Luka Trovic <luka@nextcloud.com> Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | | fix(users): improve recently active searchBenjamin Gaussorgues2024-10-301-3/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | - Remove DISTINCT clause to fix PgSQL - Join user table only if necessary - Don't show people who never connected in active list - Add test Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
* | | Merge pull request #47847 from ↵John Molakvoæ2024-10-291-0/+23
|\ \ \ | | | | | | | | | | | | nextcloud/fix-copying-or-moving-from-shared-groupfolders
| * | | test: add test for nested jail cross-storage movefix-copying-or-moving-from-shared-groupfoldersRobin Appelman2024-10-101-0/+23
| | | | | | | | | | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | | | fix: Adjust preview for view-only sharesfix/view-only-previewFerdinand Thiessen2024-10-281-17/+174
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously there was a different behavior for public shares (link-shares) and internal shares, if the user disabled the view permission. The legacy UI for public shares simply "disabled" the context menu and hided all download actions. With Nextcloud 31 all share types use the consistent permissions attributes, which simplifies code, but caused a regression: Images can no longer been viewed. Because on 30 and before the attribute was not set, previews for view-only files were still allowed. Now with 31 we need a new way to allow "viewing" shares. So this is allowing previews for those files, but only for internal usage. This is done by settin a special header, which only works with custom requests, and not by opening the URL directly. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | | | Merge pull request #48915 from nextcloud/fix/encrypt-decrypt-passwordKate2024-10-281-3/+19
|\ \ \ \
| * | | | fix: crypto type made not nullable and tests run using ICryptoyemkareems2024-10-281-5/+4
| | | | | | | | | | | | | | | | | | | | Signed-off-by: yemkareems <yemkareems@gmail.com>
| * | | | fix: encrypt and store password, decrypt and retrieve the sameyemkareems2024-10-281-3/+20
| | | | | | | | | | | | | | | | | | | | Signed-off-by: yemkareems <yemkareems@gmail.com>
* | | | | Merge pull request #48912 from ↵Ferdinand Thiessen2024-10-285-1/+78
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | nextcloud/bugfix/exception-appscreenshot-notstring fix(apps-store): Fix exception on generating preview url for installed app screenshot
| * | | | | fix(appinfo): Make sure screenshot, author and category are always arraysbugfix/exception-appscreenshot-notstringJoas Schilling2024-10-285-1/+78
| |/ / / / | | | | | | | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | | | | Merge pull request #48614 from nextcloud/refactor/storage/constructorsKate2024-10-283-6/+6
|\ \ \ \ \ | |/ / / / |/| | | |
| * | | | refactor(Storage): Align all Storage constructorsrefactor/storage/constructorsprovokateurin2024-10-233-6/+6
| | | | | | | | | | | | | | | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | | | | fix(entity): Fix mapping of old/sub-types to actually supported database typesfollowup/47329/add-all-types-to-handlingJoas Schilling2024-10-231-5/+39
|/ / / / | | | | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | | | Merge pull request #47329 from nextcloud/feat/add-datetime-qbmapper-supportFerdinand Thiessen2024-10-187-50/+243
|\ \ \ \ | | | | | | | | | | feat(AppFramework): Add full support for date / time / datetime columns
| * | | | fix: Prevent breaking change in IQueryBuilderFerdinand Thiessen2024-10-175-13/+13
| | | | | | | | | | | | | | | | | | | | Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
| * | | | feat(AppFramework): Add full support for date / time / datetime columnsFerdinand Thiessen2024-10-175-44/+237
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for all Doctrine supported types, for the column types only the immutable variants needed to be added. But especially those types are the important ones, as our **Entity** class works by detecting changes through setters. Meaning if it is mutable, changes like `$entity->date->modfiy()` can not be detected, so the immutable types make more sense here. Similar the parameter types needed to be added. `Enity` and `QBMapper` needed to be adjusted so they support (auto map) those types, required when insert or update an entity. Also added more tests, especially to make sure the mapper really serializes the values correctly. Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de> Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com> Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | | | | fix(comments): Add test for email mentionfeat/noid/support-email-mentionsJoas Schilling2024-10-181-0/+6
|/ / / / | | | | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | | / fix(code-style): Adjust JS code to our code styleFerdinand Thiessen2024-10-161-6/+0
| |_|/ |/| | | | | | | | | | | | | | This resolves 68 ESLint warnings about invalid code style. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | | Merge pull request #48673 from nextcloud/fix/null-labelFerdinand Thiessen2024-10-141-0/+34
|\ \ \ | | | | | | | | fix(share): Return empty string if no label is set
| * | | fix(share): Return empty string if no label is setFerdinand Thiessen2024-10-141-0/+34
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | * Resolves: https://github.com/nextcloud/server/issues/48629 While the database supports NULL, the typing has always said it only returns *string*. So to not break any apps that might trust the typings we should return `''` if the database is set to `NULL`. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* / | fix: Shipped apps should include the Nextcloud version in the cache busterfix/shipped-app-versionFerdinand Thiessen2024-10-141-0/+84
|/ / | | | | | | | | | | Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de> Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com> Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | Merge pull request #48537 from nextcloud/add-command-to-cleanup-previewKate2024-10-141-0/+176
|\ \ | |/ |/|
| * feat(preview): add command to cleanup preview folderadd-command-to-cleanup-previewThomas Citharel2024-10-031-0/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | When changing preview parameters (size, format, …), one can simply delete the preview folder and run files:scan-app-data in order to retrigger updated preview recreation because files are absent. However, that's not possible when using ObjectStorage as primary storage, as there's no concept of "preview folder". This command allows to simply delete and recreate the preview folder properly from Nextcloud, so that the abstraction levels handle all the subfolder & file deleting part. Signed-off-by: Thomas Citharel <tcit@tcit.fr>
* | Merge pull request #48610 from nextcloud/fix/usertrait/backend-initializationKate2024-10-081-0/+3
|\ \
| * | fix(UserTrait): Fix backend initializationfix/usertrait/backend-initializationprovokateurin2024-10-081-0/+3
| | | | | | | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | | refactor(Storage): Make all parameter types strong typesprovokateurin2024-10-073-14/+12
|/ / | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | refactor(Wrapper\Encryption): Migrate to strong typesrefactor/stream-encryption/typingsprovokateurin2024-10-071-109/+119
| | | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | refactor(Stream\Encryption): Migrate to strong typesprovokateurin2024-10-071-26/+38
| | | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | test(settings): Correctly only return bool for Symfony ↵dependabot/composer/symfony-6.4Joas Schilling2024-10-071-7/+17
| | | | | | | | | | | | Input::hasParameterOption calls Signed-off-by: Joas Schilling <coding@schilljs.com>
* | fix(message): Fix logic of Mail testJoas Schilling2024-10-071-5/+5
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | test: Fix mock creationJoas Schilling2024-10-071-4/+3
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #47896 from nextcloud/fix/resiliant-user-removalFerdinand Thiessen2024-10-071-14/+67
|\ \ | |/ |/| fix: Make user removal more resilient
| * fix: Make user removal more resilientFerdinand Thiessen2024-09-261-14/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently there is a problem if an exception is thrown in `User::delete`, because at that point the user is already removed from the backend, but not all data is deleted. There is no way to recover from this state, as the user is gone no information is available anymore. This means the data is still available on the server but can not removed by any API anymore. The solution here is to first set a flag and backup the user home, this can be used to recover failed user deletions in a way the delete can be re-tried. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | chore: always execute parse_url in preventLocalAddressbug/noid/federated-addressbook-sync-without-localaddressallowedDaniel Kesselberg2024-10-011-1/+7
| | | | | | | | | | | | This change should make it easier to spot wrong uses of the HTTP client on development setups where allow_local_remote_servers is usually true. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Merge pull request #48235 from nextcloud/readd-object-store-phpunitRobin Appelman2024-10-011-0/+15
|\ \ | | | | | | test: re-add object store primary storage phpunit tests
| * | test: re-add object store primary storage phpunit testsRobin Appelman2024-09-271-0/+15
| | | | | | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | | chore: Drop unused legacy `OC_Files`Ferdinand Thiessen2024-09-281-2/+2
| | | | | | | | | | | | | | | | | | It is replaced with the Sabre `ZipFolderPlugin` and apps should use the `OCP\AppFramework\Http\StreamResponse`. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* | | feat(files): Make the files download action use WebDAV zip downloadFerdinand Thiessen2024-09-281-7/+7
|/ / | | | | | | Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* / test: Fix IStorage return typesprovokateurin2024-09-265-11/+45
|/ | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* Merge pull request #32018 from nextcloud/cleanup/event/trashbinCôme Chilliet2024-09-242-2/+17
|\ | | | | Port files trashbin events to IEventDispatcher/IEventListener
| * fix(tests): Pause trashbin for lock tests in ViewTest using rmdir and unlinkcleanup/event/trashbinCôme Chilliet2024-09-241-1/+16
| | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>