summaryrefslogtreecommitdiffstats
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Restore old behavior allowing to set custom appstoreGeorg Ehrke2020-01-062-1/+18
| | | | Signed-off-by: Georg Ehrke <developer@georgehrke.com>
* Update the unit test to dataProvidersJoas Schilling2019-12-121-42/+77
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Move overwritehost check to isTrustedDomainJulius Härtl2019-12-091-1/+16
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* Handle token insert conflictsChristoph Wurst2019-12-021-11/+44
| | | | | | | | | | | | | | | | Env-based SAML uses the "Apache auth" mechanism to log users in. In this code path, we first delete all existin auth tokens from the database, before a new one is inserted. This is problematic for concurrent requests as they might reach the same code at the same time, hence both trying to insert a new row wit the same token (the session ID). This also bubbles up and disables user_saml. As the token might still be OK (both request will insert the same data), we can actually just check if the UIDs of the conflict row is the same as the one we want to insert right now. In that case let's just use the existing entry and carry on. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Do not check for updates if we have no internetRoeland Jago Douma2019-11-201-24/+64
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Harden middleware checkRoeland Jago Douma2019-10-251-4/+85
| | | | | | | These annotations will allow for extra checks. And thus make it harder to break things. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* fix oauth client redirectSergej Nikolaev2019-10-071-1/+2
| | | | Signed-off-by: Sergej Nikolaev <kinolaev@gmail.com>
* fix updating and deleting authtokensSergej Nikolaev2019-10-051-0/+45
| | | | Signed-off-by: Sergej Nikolaev <kinolaev@gmail.com>
* adjust test expectationsArthur Schiwon2019-10-011-2/+1
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Merge pull request #17277 from nextcloud/backport/17264/stable17Roeland Jago Douma2019-09-271-20/+97
|\ | | | | [stable17] handle moveFromStorage within the same storage even when storage wrap…
| * handle moveFromStorage within the same storage even when storage wrappers ↵Robin Appelman2019-09-261-20/+97
| | | | | | | | | | | | | | | | | | | | are applied to the source storage the target storage doesn't need additional handling for wrappers as the wrappers implementation of moveFromStorage already deals with that Any storage based on local storage isn't affected by this as local storage already has it's own way of handling with this Signed-off-by: Robin Appelman <robin@icewind.nl>
* | dont delete cache entries if deleting an object from object store failedRobin Appelman2019-09-262-0/+79
|/ | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Use the actual password to update the tokensRoeland Jago Douma2019-09-181-2/+2
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* adjust testsArthur Schiwon2019-09-091-41/+53
| | | | Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
* Merge pull request #16454 from ↵Roeland Jago Douma2019-09-041-8/+0
|\ | | | | | | | | nextcloud/bugfix/noid/sharelink-shouldnt-open-menu-automatically Dont show menu automatically when share link is clicked
| * Adjust acceptance tests to changes in link share menu behaviourGreta Doci2019-08-291-8/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now the link share menu is not automatically opened after a link share is created, so waiting until it was opened failed in iShareTheLinkFor. Note that the steps that interact with the link share menu take care themselves of showing the menu if needed, so there is no need to explicitly show it despite the change. Also, the waiting in iShareTheLinkFor was introduced when the link share menu was changed to automatically open after creating a link share, as that caused some issues with the steps that opened the menu by themselves (fec8d12fc5). Due to all this, now that the link share menu is again not automatically opened the wait can be simply removed. Signed-off-by: Greta Doci <gretadoci@gmail.com>
* | Add default timeout to expected request optionsDaniel Kesselberg2019-09-031-34/+19
|/ | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* SessionMiddleware: declare session propertyRoeland Jago Douma2019-08-281-12/+4
| | | | | | | * Remove request since we don't useit * Update tests as well Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #16879 from only-run-integration-tests-on-php-changesJohn Molakvoæ2019-08-271-0/+15
|\ | | | | Only run integration tests when PHP was modified
| * Only run integration tests when PHP was modifiedJoas Schilling2019-08-271-0/+15
| | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #16875 from nextcloud/bugfix/16874/welcome-mail-client-urlRoeland Jago Douma2019-08-271-5/+12
|\ \ | | | | | | Use custom client URL in welcome emails
| * | Mock client URL in new user mail testsJulius Härtl2019-08-271-5/+12
| | | | | | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | | Merge pull request #16865 from nextcloud/bugfix/noid/5-min-cronRoeland Jago Douma2019-08-261-23/+2
|\ \ \ | |_|/ |/| | Cron should run every 5 mins
| * | Cleanup the Settings classJoas Schilling2019-08-261-23/+2
| |/ | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* | Merge pull request #16795 from nextcloud/enh/phpstan/limiterJohn Molakvoæ2019-08-261-8/+0
|\ \ | |/ |/| Fix report of phpstan in Limiter
| * Fix report of phpstan in LimiterRoeland Jago Douma2019-08-191-8/+0
| | | | | | | | | | | | | | | | * unneeded arguments to constructor * added return types * let automatic DI do its work Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Merge pull request #16782 from nextcloud/fix/16729/stop-if-encrypted-token-nullblizzz2019-08-211-1/+17
|\ \ | |/ |/| Stop if there is no encrypted token
| * Add test case for existing user with token nullDaniel Kesselberg2019-08-181-0/+16
| | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
| * Return the disabled user mock instead of the existingDaniel Kesselberg2019-08-181-1/+1
| | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | Allow Context subclasses in acceptance tests to access parent actorDaniel Calviño Sánchez2019-08-161-1/+1
|/ | | | | | | | | | Although uncommon, in some cases a Context may need to be extended (for example, to override a step defined in the server with a specific behaviour in the acceptance tests of an app); in those cases the subclass should be able to access the actor attribute defined in the Context it is extending. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
* Merge pull request #16711 from nextcloud/fix/csp/form_actions/loginflowRoeland Jago Douma2019-08-121-0/+6
|\ | | | | Fix login flow form actions
| * Fix login flow form actionsRoeland Jago Douma2019-08-111-0/+6
| | | | | | | | | | | | | | | | So fun fact. Chrome considers a redirect after submitting a form part of the form actions. Since we redirect to a new protocol (nc://login/). Causing the form submission to work but the redirect failing hard. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Merge pull request #16721 from nextcloud/fix/16644Roeland Jago Douma2019-08-111-2/+12
|\ \ | | | | | | Correctly handle emtpy string in proxyuserpwd config
| * | Correctly handle emtpy string in proxyuserpwd configScott Shambarger2019-08-111-2/+12
| |/ | | | | | | | | | | | | | | | | | | As documented, the default value for config value proxyuserpwd is ''. However, that value results in the error: "cURL error 5: Unsupported proxy syntax in '@'". This patch handles the values of '' and null (the default in the code) the same for config values proxyuserpwd and proxy. Signed-off-by: Scott Shambarger <devel@shambarger.net>
* | Add testsRoeland Jago Douma2019-08-105-0/+492
| | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Add feature policy headerRoeland Jago Douma2019-08-103-1/+4
|/ | | | | | | This adds the events and the classes to modify the feature policy. It also adds a default restricted feature policy. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #16592 from nextcloud/bugfix/noid/federated-reshareRoeland Jago Douma2019-08-011-0/+33
|\ | | | | Fix permission check on incoming federated shares
| * Fix permission check on incoming federated sharesJulius Härtl2019-07-311-0/+33
| | | | | | | | | | | | | | | | Since federated shares have their permissions set on the node, we do not need to check for parent share permissions. Otherwise reshares of incoming federated have no permission variable defined and creating them will fail Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Update CSP test cases to handle the new form-actionRoeland Jago Douma2019-07-312-60/+64
|/ | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #16544 from nextcloud/bugfix/16540Roeland Jago Douma2019-07-311-5/+15
|\ | | | | Add missing password reset page to vue
| * Move actual password reset to vueJulius Härtl2019-07-311-5/+15
| | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | Merge pull request #16594 from ↵Joas Schilling2019-07-301-29/+0
|\ \ | | | | | | | | | | | | nextcloud/tech-debt/noid/remove-unused-checkPasswordProtectedShare Remove unused OC\Share\Share::checkPasswordProtectedShare
| * | Remove unused OC\Share\Share::checkPasswordProtectedShareMorris Jobke2019-07-291-29/+0
| | | | | | | | | | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* | | Merge pull request #16579 from nextcloud/enh/PostLoginEventRoeland Jago Douma2019-07-301-44/+71
|\ \ \ | | | | | | | | Add proper PostLoginEvent
| * | | Update testsRoeland Jago Douma2019-07-291-44/+71
| |/ / | | | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | | Merge pull request #16502 from nextcloud/bugfix/16474Morris Jobke2019-07-291-7/+14
|\ \ \ | |/ / |/| | Check the if we can actually access the storage cache for recent files
| * | Check the if we can actually access the storage cache for recent filesJulius Härtl2019-07-241-7/+14
| | | | | | | | | | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* | | Merge pull request #16582 from nextcloud/enh/split_up_security_middlewareRoeland Jago Douma2019-07-292-97/+149
|\ \ \ | | | | | | | | Split up security middleware
| * | | Split up security middlewareRoeland Jago Douma2019-07-272-97/+149
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | With upcoming work for the feature policy header. Splitting this in smaller classes that just do 1 thing makes sense. I rather have a few small classes that are tiny and do 1 thing right (and we all understand what is going on) than have big ones. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* / | Use proper exception in lostControllerRoeland Jago Douma2019-07-271-3/+9
|/ / | | | | | | | | | | | | | | | | | | There is no need to log the expcetion of most of the stuff here. We should properly log them but an exception is excessive. This moves it to a proper exception which we can catch and then log. The other exceptions will still be fully logged. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>