aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib
Commit message (Collapse)AuthorAgeFilesLines
* fix(appinfo): Make sure screenshot, author and category are always arraysbackport/48912/stable30Joas Schilling2024-11-011-0/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.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>
* test: add test for nested jail cross-storage movebackport/47847/stable30Robin Appelman2024-10-291-0/+23
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix: crypto added manually as expectedbackport/48915/stable30yemkareems2024-10-281-1/+1
| | | | Signed-off-by: yemkareems <yemkareems@gmail.com>
* fix: crypto type made not nullable and tests run using ICryptoyemkareems2024-10-281-4/+3
| | | | Signed-off-by: yemkareems <yemkareems@gmail.com>
* fix: encrypt and store password, decrypt and retrieve the sameyemkareems2024-10-281-2/+19
| | | | Signed-off-by: yemkareems <yemkareems@gmail.com>
* fix(message): Fix logic of Mail testJoas Schilling2024-10-211-5/+5
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* fix(comments): Add test for email mentionbackport/48760/stable30Joas Schilling2024-10-181-0/+6
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #48703 from nextcloud/backport/48673/stable30Ferdinand Thiessen2024-10-171-0/+34
|\ | | | | [stable30] 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(UserTrait): Fix backend initializationbackport/47896/stable30provokateurin2024-10-081-0/+3
| | | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* | fix: Make user removal more resilientFerdinand Thiessen2024-10-081-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>
* Merge pull request #48077 from nextcloud/backport/47852/stable30Benjamin Gaussorgues2024-10-022-14/+14
|\
| * fix: misc code fixes around db shardingbackport/47852/stable30Robin Appelman2024-09-162-14/+14
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | fix: gracefully parse non-standard trusted certificatesbackport/48307/stable30Richard Steinmetz2024-09-301-2/+7
| | | | | | | | Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
* | fix(users): Don't crash if disabled user is missing in the databasebackport/48207/stable30Louis Chemineau2024-09-235-30/+48
| | | | | | | | Signed-off-by: Louis Chemineau <louis@chmn.me>
* | Merge pull request #48221 from nextcloud/backport/30/fix_move_on_same_bucketKate2024-09-203-0/+182
|\ \
| * | fix(tests): Fix most obvious errors in ObjectStore testsbackport/30/fix_move_on_same_bucketCôme Chilliet2024-09-193-56/+60
| | | | | | | | | | | | | | | | | | Some are still failing Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
| * | perf(ObjectStoreStorage): Improve (slow) move on same object bucketChristoph Fiehe2024-09-193-0/+178
| | | | | | | | | | | | | | | | | | | | | | | | | | | This commit fixes the issue #47856. When you upload a file into a group folder and when you use a single S3 bucket as primary storage, the final move operation hangs for a long time. In the background, Nextcloud initiates a copy-delete sequence from the bucket into the bucket, with causes a lot unnecessary overhead. Nextcloud thinks that the file must be imported to another storage and does not recognize that everything is done on the same object bucket. In that case, the import step can be completely skipped, which saves time, network bandwidth and reduces the load on the object storage. The behavior improves a lot with https://github.com/nextcloud/server/pull/46013. However, there are still some put messages that are being sent to the object storage when you use an object storage as primary storage and upload files into a group folder. Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com> Signed-off-by: Christoph Fiehe <c.fiehe@eurodata.de>
* | | fix(tests): Fix Folder testsCôme Chilliet2024-09-191-3/+22
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | | fix(tests): Remove deprecated tests for ServerTestCôme Chilliet2024-09-191-113/+7
| | | | | | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | | test: put parent items into cache in testsRobin Appelman2024-09-195-50/+83
| | | | | | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | | test: fix incorrect ltrim usage in testRobin Appelman2024-09-191-2/+2
|/ / | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Merge pull request #48088 from nextcloud/backport/48008/stable30Kate2024-09-171-2/+7
|\ \
| * | fix(Entity): Fix magic setter call for custom strong typed settersbackport/48008/stable30provokateurin2024-09-161-2/+7
| |/ | | | | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* / fix(config): add envCache tests for getKeys()Josh Richards2024-09-161-0/+7
|/ | | | Signed-off-by: Josh Richards <josh.t.richards@gmail.com>
* Merge pull request #47940 from nextcloud/backport/47933/stable30Andy Scherzinger2024-09-151-0/+36
|\ | | | | [stable30] fix(config): Throw PreconditionException always when it didn't match
| * fix(config): Throw PreconditionException always when it didn't matchbackport/47933/stable30Joas Schilling2024-09-131-0/+36
| | | | | | | | | | | | | | | | Previously even when the precondition did not match, the call "passed" when the after value was the expected one. This however can lead to race conditions, duplicate code excutions and other things. Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #47796 from nextcloud/backport/47756/stable30Andy Scherzinger2024-09-151-1/+9
|\ \ | |/ |/| [stable30] fix(files): Check if target path is a descendant of the shared folder
| * fix(files): Check if the target path is a descendant of the shared folder pathbackport/47756/stable30Git'Fellow2024-09-061-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> fix: tests Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> fix: fix tests Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> fix: add tests Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> fix: tests
* | fix: Add whiteboard to education and public sector bundleJulius Knorr2024-09-121-0/+1
|/ | | | Signed-off-by: Julius Knorr <jus@bitgrid.net>
* fix(files): Create non-existent parents of mountpointsprovokateurin2024-09-041-0/+31
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* fix: Adjust filename validation messagesFerdinand Thiessen2024-08-301-1/+1
| | | | Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* fix(TaskProcessing): Fix namespace of TaskProcessingTest.phpMarcel Klehr2024-08-301-1/+1
| | | | | Signed-off-by: Marcel Klehr <mklehr@gmx.net> Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* fix(taskprocessing): fix testsJulien Veyssier2024-08-302-13/+5
| | | | Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
* test(phpunit): skip sharding tests on 32bitArthur Schiwon2024-08-292-0/+6
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* fix: Renaming does not need update but delete permissionsFerdinand Thiessen2024-08-281-3/+3
| | | | | | | Renaming is basically copy + delete (a move), so no need to update permissions. Especially if the node is in a invalid directory the node should be moveable but not editable. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* fix: Backport to 30Louis Chemineau2024-08-281-2/+2
| | | | Signed-off-by: Louis Chemineau <louis@chmn.me>
* chore: Apply php:cs recommendationsLouis Chemineau2024-08-284-12/+12
| | | | | | Signed-off-by: Louis Chemineau <louis@chmn.me> [skip ci]
* fix: implement sharding compatible cleanup for various bitsRobin Appelman2024-08-282-9/+8
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* test: fix share provider tests for shardingRobin Appelman2024-08-282-6/+6
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* test: mark share test cleanup as running across all shardsRobin Appelman2024-08-281-0/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* feat: implement distributing partitioned queries over multiple shardsRobin Appelman2024-08-285-2/+154
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* feat: add option to automatically partition queries by specific tablesRobin Appelman2024-08-282-0/+290
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix: delay calculating global cache prefix untill a cache is createdRobin Appelman2024-08-281-3/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* feat: add negative compare-and-delete to imemcacheRobin Appelman2024-08-231-0/+23
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix: `FilenameValidator::isForbidden` should only check forbidden filesFerdinand Thiessen2024-08-221-17/+7
| | | | | | And not forbidden basenames as this is used for different purposes. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* ci: Skip flaky test on PHP 8.3Joas Schilling2024-08-211-0/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #43573 from nextcloud/HolgerHees-fix-csp-nonce-handlingFerdinand Thiessen2024-08-134-262/+267
|\ | | | | Fix for ignored `CSP_NONCE` in ContentSecurity Header
| * feat: Provide CSP nonce as `<meta>` elementFerdinand Thiessen2024-08-131-1/+0
| | | | | | | | | | | | | | | | This way we use the CSP nonce for dynamically loaded scripts. Important to notice: The CSP nonce must NOT be injected in `content` as this can lead to value exfiltration using e.g. side-channel attacts (CSS selectors). Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>