summaryrefslogtreecommitdiffstats
path: root/apps/sharebymail/tests
Commit message (Collapse)AuthorAgeFilesLines
* Update php licensesJohn Molakvoæ (skjnldsv)2021-06-042-5/+6
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Fix testsJohn Molakvoæ (skjnldsv)2021-03-222-19/+41
| | | | Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Add labels to mail sharesJohn Molakvoæ (skjnldsv)2021-03-221-0/+3
| | | | | | Now the email is shown on a second line if a label is set. Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
* Sharebymail: set expiration on creationRoeland Jago Douma2021-03-041-1/+4
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* ReplyTo option for sharebymail Issue #24139Nicolas SIMIDE2021-01-281-0/+186
| | | | Signed-off-by: Nicolas SIMIDE <2083596+dems54@users.noreply.github.com>
* Don't leave cursors open when tests failJoas Schilling2020-11-091-10/+28
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Format code to a single space around binary operatorsChristoph Wurst2020-10-051-3/+3
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 20Christoph Wurst2020-08-241-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Change PHPDoc type hint from PHPUnit_Framework_MockObject_MockObject to ↵Morris Jobke2020-08-121-14/+13
| | | | | | \PHPUnit\Framework\MockObject\MockObject Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Generate password by password_policy appDaniel Kesselberg2020-08-111-8/+17
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* Fix sharebymail testsRoeland Jago Douma2020-07-063-99/+13
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update share type constant usageJoas Schilling2020-06-241-4/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Fix creating a mail share with a passwordDaniel Calviño Sánchez2020-05-281-0/+98
| | | | | | | | | | When a mail share was created with a password the given password was not hashed, so it was not possible to open the share with that password. Moreover, if passwords were enforced the given password was ignored and a new one was set (although in this case it was hashed so it worked as expected). Now the given password is properly hashed and not overriden. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Extend mail shares unit tests to check the password and mail templateDaniel Calviño Sánchez2020-05-281-2/+23
| | | | Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Update license headers for 19Christoph Wurst2020-04-292-0/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-102-12/+1
| | | | | | | | | | | | | | | 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>
* Remove trailing and in between spacesChristoph Wurst2020-04-091-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Unify function spacing to PSR2 recommendationChristoph Wurst2020-04-091-2/+2
| | | | 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-091-7/+7
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Update the license headers for Nextcloud 19Christoph Wurst2020-03-311-0/+1
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use the shorter phpunit syntax for mocked return valuesChristoph Wurst2020-03-251-2/+2
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Properly respect hide download on sharebymailRoeland Jago Douma2020-03-131-6/+9
| | | | | | fixes #19484 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update license headersChristoph Wurst2019-12-053-3/+19
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Mode to modern phpunitRoeland Jago Douma2019-11-273-19/+19
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Fix more testsRoeland Jago Douma2019-11-271-1/+1
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Make phpunit8 compatibleRoeland Jago Douma2019-11-273-5/+5
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Some php-cs fixesRoeland Jago Douma2019-11-222-2/+0
| | | | | | | | | | | * 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>
* Unshare from mail activity is missingJoas Schilling2018-12-041-1/+2
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* OCA\ShareByMail\Capabilities unit testMasterOfDeath2018-10-311-0/+51
| | | | | | OCA\ShareByMail\Capabilities unit test Signed-off-by: Rinat Gumirov <rinat.gumirov@mail.ru>
* Honour "sendPasswordByTalk" property in mail sharesDaniel Calviño Sánchez2018-07-241-0/+156
| | | | | | | | | | | | | | | | | When a password was set for a mail share an e-mail was sent to the recipient with the password. Now the e-mail is no longer sent if the password is meant to be sent by Talk. However, before the e-mail was not sent when the share was updated but the password was not changed. Now an e-mail is sent in that case too if switching from a password sent by Talk to a password sent by mail. On the other hand, when switching from a password sent by mail to a password sent by Talk it is mandatory to change the password; otherwise the recipient would already have access to the share without having to call the sharer to verify her identity. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Store "sendPasswordByTalk" property of mail shares in the databaseDaniel Calviño Sánchez2018-07-241-1/+4
| | | | Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* fix unit testsBjoern Schiessle2018-07-211-7/+11
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* Use ::class in test mocks of dav appMorris Jobke2017-10-261-2/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Use ::class in test mocksMorris Jobke2017-10-241-4/+4
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Set the data from the templateJoas Schilling2017-10-181-32/+8
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* expect call of getSlogan() exactly twiceStephan Müller2017-09-251-1/+1
| | | | | Signed-off-by: Stephan Müller <mail@stephanmueller.eu> Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Allow the expiration date to be set to nullMorris Jobke2017-08-261-0/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* don't mention the owner of a file in case of a re-share by mail. The ↵Bjoern Schiessle2017-05-081-24/+8
| | | | | | recipient doesn't care about the owner and probably don't even know it Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* fix unit testsBjoern Schiessle2017-04-201-4/+4
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* respect password policy for auto generated passwordsBjoern Schiessle2017-04-201-2/+9
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* allow admin to enforce password on mail sharesBjoern Schiessle2017-04-202-6/+56
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* Rename renderHTML to renderHtmlMorris Jobke2017-04-191-2/+2
| | | | | | | * fixes #4383 * improves consistency Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Add "Reply-To" on ShareByMailProvider mailsLukas Reschke2017-04-181-2/+237
| | | | | | Fixes https://github.com/nextcloud/server/issues/4209 Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
* Mail shares trigger the public keyRoeland Jago Douma2017-04-131-16/+16
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Adjust docs and make !$currentAccess simplerJoas Schilling2017-04-131-0/+7
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Add unit tests for sharebymail providerJoas Schilling2017-04-131-0/+55
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* update unit testsBjoern Schiessle2017-04-071-5/+3
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* setting to disable sending password by mailBjoern Schiessle2017-04-031-1/+7
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
* allow password protected mail sharesBjoern Schiessle2017-04-031-0/+1
| | | | Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>