Daniel Calviño Sánchez
34a143b05f
Add integration tests for creating shares with default expiration dates
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:17:01 +00:00
Daniel Calviño Sánchez
bf844567a5
Reset app configs by deleting the values instead of setting the defaults
...
This avoids the need to keep the default values in the integration tests
in sync with the code, and also makes possible to reset values with
"dynamic" defaults (defaults that depend on other values).
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:17:00 +00:00
Daniel Calviño Sánchez
1464ace788
Add unit tests for "validateExpirationDateInternal"
...
They were copied and adjusted as needed from the tests for
"validateExpirationDate".
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:59 +00:00
Daniel Calviño Sánchez
182e28bfbc
Fix default internal expiration date
...
The default expiration date for internal shares was set from the default
link expiration date instead of the internal one.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:57 +00:00
Daniel Calviño Sánchez
709abd4fc7
Add explicit time to test date for clarity
...
This shows in a clearer way that the expected expiration date is the
original one, but without time.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:56 +00:00
Daniel Calviño Sánchez
731cce4542
Add unit test for expiration date with date and with default
...
This adds back what was being actually tested in the unit test fixed in
the previous commit.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:55 +00:00
Daniel Calviño Sánchez
115a988cd2
Fix unit test for expiration date without date but with default
...
The expiration date was explicitly given, so it was not testing what it
should. Moreover, "link_defaultExpDays" needs to be mapped when testing
the default value (even if it will just fallback to the value of
"shareapi_expire_after_n_days").
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:53 +00:00
Daniel Calviño Sánchez
eaa43d22e2
Fix unit test method name
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:52 +00:00
Daniel Calviño Sánchez
4e418100bf
Fix unit test for verifying enforced valid expiration date.
...
The enforced expiration date was not actually enabled, as for that
"shareapi_default_expire_date" needs to be explicitly set to "yes".
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:51 +00:00
Daniel Calviño Sánchez
20c72ac03e
Fix unit test for verifying enforced expire date too far in the future
...
The test should fail if no exception was thrown, and no exception was
thrown due to a missing configuration parameter. However, the use of
"addToAssertionCount(1)" made the test pass even if no exception was
thrown and, therefore, to silently fail.
Now the missing configuration parameter was added and the test will fail
if the expected exception is not thrown.
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:49 +00:00
Daniel Calviño Sánchez
22357a72e5
Add unit tests to enforce a relaxed default share expiration date
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:48 +00:00
Daniel Calviño Sánchez
b75c171ee2
Remove wrong and misleading comment
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:47 +00:00
Daniel Calviño Sánchez
d6ba3b2f7c
Remove extra spaces
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:45 +00:00
Daniel Calviño Sánchez
76bbbca220
Fix typo in variable name
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:44 +00:00
Daniel Calviño Sánchez
446c90879f
Fix typos in method names
...
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2020-11-16 13:16:42 +00:00
Roeland Jago Douma
b14ec966c1
Merge pull request #24156 from nextcloud/backport/24112/stable20
...
[stable20] Set up FS before querying storage info in settings
2020-11-16 14:14:43 +01:00
John Molakvoæ
f4d92d2e3a
Merge pull request #24153 from nextcloud/dependencies/dompurify
2020-11-16 13:12:40 +01:00
Roeland Jago Douma
bca0633e2b
Merge pull request #24147 from nextcloud/backport/24146/stable20
...
[stable20] Don't throw on SHOW VERSION query
2020-11-16 12:08:56 +01:00
Vincent Petry
32758894a4
Set up FS before querying storage info in settings
...
The personal info section of the personal settings is querying the
storage quota information. For this it requires the FS to be setup which
is not always guaranteed.
This fixes an issue where refreshing the settings page would cause it to
fail after Redis caches are full. It is likely that when Redis cache is
populated, some code path is initializing the FS, so it works so far.
But when the cache is populated, that code path is skipped so the FS is
not guaranteed to be setup...
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2020-11-16 11:06:35 +00:00
Julius Härtl
889d162ab7
Bump bundles
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-11-16 11:36:35 +01:00
Julius Härtl
ccc845b1c4
Bump dompurify to 2.2.2
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2020-11-16 11:30:59 +01:00
Joas Schilling
7a821da1bc
Merge pull request #24079 from nextcloud/backport/24053/stable20
...
[stable20] Make is_user_defined nullable so we can store false on oracle
2020-11-16 11:23:17 +01:00
John Molakvoæ
18f5ad1a34
Merge pull request #24114 from nextcloud/backport/24096/stable20
...
[stable20] Convert the card resource to a string if necessary
2020-11-16 10:15:18 +01:00
Joas Schilling
f10327b245
Don't throw on SHOW VERSION query
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-16 08:59:47 +00:00
Joas Schilling
9b694e59f5
Bump versions
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-16 08:54:30 +01:00
Joas Schilling
d334dd1455
Merge pull request #24106 from nextcloud/backport/24085/stable20
...
[stable20] Register new command db:add-missing-primary-keys
2020-11-16 08:50:01 +01:00
Nextcloud bot
9abc65c573
[tx-robot] updated from transifex
2020-11-16 02:19:33 +00:00
Nextcloud bot
c9001eb7ef
[tx-robot] updated from transifex
2020-11-15 02:19:11 +00:00
Nextcloud bot
66b6ccc69e
[tx-robot] updated from transifex
2020-11-14 02:19:47 +00:00
Christoph Wurst
07861fe52d
Convert the card resource to a string if necessary
...
Apparently the fetched column can be a string or resource. Hence we have
to catch the resource type and convert it to a string.
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2020-11-13 18:18:24 +00:00
MichaIng
e0dbfdf575
Register new command db:add-missing-primary-keys
...
Introduced with: d5df033ede
Signed-off-by: MichaIng <micha@dietpi.com>
2020-11-13 14:41:51 +00:00
Roeland Jago Douma
bf95044a29
20.0.2 RC2
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-13 08:38:57 +01:00
Roeland Jago Douma
8ebafbb7dc
Merge pull request #24081 from nextcloud/backport/24066/stable20
...
[stable20] Fix default internal expiration date enforce
2020-11-13 08:37:54 +01:00
John Molakvoæ (skjnldsv)
680853d077
Fix default internal expiration date enforce
...
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Signed-off-by: npmbuildbot-nextcloud[bot] <npmbuildbot-nextcloud[bot]@users.noreply.github.com>
2020-11-13 06:31:16 +00:00
Nextcloud bot
584cfa4e2e
[tx-robot] updated from transifex
2020-11-13 02:19:35 +00:00
Morris Jobke
ca363131d9
Dump autoloader
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-11-12 20:46:59 +00:00
Joas Schilling
1def6f92ee
Also make direct_edit.accessed nullable
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 20:46:57 +00:00
Joas Schilling
32d7459d8b
Make is_user_defined nullable so we can store false on oracle
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 20:46:55 +00:00
Roeland Jago Douma
105fc60eb1
Merge pull request #23989 from nextcloud/version/20.0.2/rc1
...
20.0.2 RC1
2020-11-12 21:08:19 +01:00
Roeland Jago Douma
e61e3f9eb3
20.0.2 RC1
...
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2020-11-12 19:57:13 +01:00
Morris Jobke
2e3637f826
Merge pull request #24049 from nextcloud/backport/23882/stable20
...
[stable20] Run unit tests against oracle
2020-11-12 19:54:36 +01:00
Morris Jobke
9497dca2b0
Update psalm-baseline
...
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2020-11-12 19:38:06 +01:00
Robin Appelman
388b3107eb
fix migration of oc_credentials table
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2020-11-12 15:56:34 +01:00
Joas Schilling
d09a22069f
Update baseline, I'm sorry
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
dabed84bd4
Fix unique key in test table
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
07c28f1576
Fix naming of jobs and steps
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
cd76043691
Fix CS
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
bb52911d16
Create primary keys on all tables and add a command to create the afterwards
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
f3c183b6c3
Replace the credentials table with one that can have empty user
...
Primary key columns on Oracle can not have empty strings
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:52 +01:00
Joas Schilling
dee42027ed
Don't try to update on NotNullConstraintViolationException, only on unique or foreign key
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2020-11-12 12:57:51 +01:00