Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2021-04-21Merge pull request #23529 from Simounet/feat/23397-settings-new-user-modalJohn Molakvoæ
Settings: new user row replaced by a modal
2021-04-21set mimetype for objects uploaded to object storagesRobin Appelman
Signed-off-by: Robin Appelman <robin@icewind.nl>
2021-04-21Settings: new user row replaced by a modalSimounet
Signed-off-by: Simounet <contact@simounet.net>
2021-04-21Merge pull request #26669 from nextcloud/nickvergessen-patch-1Morris Jobke
Fix PHP CS
2021-04-21Merge pull request #25991 from nextcloud/update-acceptance-tests-to-selenium3John Molakvoæ
2021-04-21Update CredentialsManagerTest.phpJoas Schilling
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-20Merge pull request #26654 from ↵Morris Jobke
nextcloud/bugfix/noid/fix-security-credentials-manager-test Fix security credentials manager test
2021-04-20Move 2FA registration to IBootstrapRoeland Jago Douma
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-20Fix support testsJoas Schilling
2) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #0 (35, 15, 2, false) Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist 3) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #1 (35, 45, 15, false) Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist 4) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #2 (35, 45, 5, true) Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist 5) Test\Support\Subscription\RegistryTest::testDelegateIsHardUserLimitReachedWithoutSupportAppAndUserCount with data set #3 (35, 45, 55, false) Cannot stub or mock class or interface "Test\Support\Subscription\UserInterface" which does not exist Had to use the Database user backend, as using multiple interfaces is deprecated: https://github.com/sebastianbergmann/phpunit/issues/3955 > This functionality should be deprecated as "having to use it" is almost always a symptom of bad design. > More importantly, though, the support for the creation of test doubles that implement multiple interfaces > resulted in code that is hard to maintain. Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-20Fix security credentials manager testJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-20save a whitespace todayblizzz
Co-authored-by: Joas Schilling <213943+nickvergessen@users.noreply.github.com> Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-04-20ignore mail shares of related remote share resultsArthur Schiwon
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-04-19Add automatic handling of "ElementNotInteractable" exceptionsDaniel Calviño Sánchez
In the WebDriver protocol, when a command fails because it can not interact with the target element, an "element not interactable" error is generated. It can be a transitive issue (for example, due to an animation), so when the error is received the command should be tried again, just like done, for example, with "ElementNotVisible" exceptions. However, the last version of the "instaclick/php-webdriver" library compatible with the Selenium Driver of Mink did not support yet that WebDriver error. And even if Chrome is run using the old protocol an unknown "element not interactable" error can be received anyway in some cases. When an unknown error is received by the "instaclick/php-webdriver" library it is thrown as a generic Exception so, until the library can be updated, the message of generic exceptions is checked and the command is retried if it matched. For the time being "element not interactable" errors are handled like "ElementNotVisible" exceptions; this may need to change once the error is better understood. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-04-19Merge pull request #26555 from nextcloud/techdebt/noid/run-migrator-tests-on-OCIJoas Schilling
Run migrator tests on OCI
2021-04-16Update acceptance tests to Selenium 3Daniel Calviño Sánchez
The acceptance tests used the last Selenium 2 Docker container available, which provides a rather old Firefox version (Firefox 47). Nevertheless, despite some rendering issues, most things still worked as expected due to the JavaScript files being built with support for older browsers. However, now that support for Internet Explorer 11 and older browsers will be dropped things could start to fail, so a newer browser (and thus a newer Selenium version) should be used in the acceptance tests. Selenium has been standardized by the W3C, and the protocol to communicate between the Selenium server and the browser has changed due to that. Firefox >= 48 only supports the new W3C protocol, but the Selenium driver for Mink does not support it yet. The old protocol can still be used in recent Chromium/Chrome versions by explicitly forcing it, so for the time being the acceptance tests will need to be run on Chrome instead (although Firefox provides some interesting features like the fake streams that would be needed to test calls in Talk, so they should be moved again to Firefox once possible). Finally, the default shm size of Docker is 64 MiB. This does not seem enough to run newer Chrome releases and causes the browser to randomly crash during the tests ("unknown error: session deleted because of page crash" is shown in the logs). Due to this "disable-dev-shm-usage" needs to be used so Chrome writes shared memory files into "/tmp" instead of "/dev/shm" (the default shm size of Docker could have been increased instead using "docker run --shm-size...", but that seems to be problematic when the container is run in current Drone releases). Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-04-16Replace carriage return with WebDriver "ENTER" constantDaniel Calviño Sánchez
When the value is set in some input fields a carriage return was sent to simulate pressing the enter key and thus confirming the input. However, different browsers use different keys (Firefox uses "\r", but Chrome uses "\n"), so the carriage return was replaced with the WebDriver "ENTER" constant which is common to both browsers. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-04-16Do not send "enter" key when not neededDaniel Calviño Sánchez
Sending the "enter" key is not needed in those input fields that auto save while the user is typing or when the focus is lost (which since version 1.4.0 the Selenium driver for Mink is automatically done after setting the value). Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-04-16Allow registering NotifierServices trough IBootstrapRoeland Jago Douma
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-16Integer 0 is not stored as Null and therefor worksJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-16Test that oracle throws on EmptyValues in a NotNull columnsJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-16Run migrator tests on OCIJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-04-16Fix unit testRoeland Jago Douma
* Fix namespace * Fix test Was broken after https://github.com/nextcloud/server/pull/26529 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2021-04-15Separate settings for remote share expirationVincent Petry
Added separate settings for default and enforced expiration date for remote shares. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-04-12Merge pull request #26266 from nextcloud/future-proof-networkingRoeland Jago Douma
Improve networking checks
2021-04-07Increase subnet matcherLukas Reschke
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-04-06Merge pull request #24966 from nextcloud/jknockaert-patch-1Lukas Reschke
avoid fread on directories and unencrypted files
2021-04-06Adjust testLukas Reschke
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-04-06Improve networking checksLukas Reschke
Whilst we currently state that SSRF is generally outside of our threat model, this is something where we should invest to improve this. Signed-off-by: Lukas Reschke <lukas@statuscode.ch>
2021-04-01Merge pull request #24055 from ↵Morris Jobke
nextcloud/bugfix/noid/enfore-no-notnull-for-boolean-to-store-false Enforce no notnull for boolean to store false
2021-04-01Get the parent directory before creating a file from a templateJulius Härtl
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2021-03-31Rename the method to match what it doesJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-03-31Don't allow Notnull for boolean columnsJoas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-03-31Merge pull request #25961 from nextcloud/enh/events/2fa_providerkesselb
Add real events for enabled 2fa providers for users
2021-03-30Merge pull request #25280 from nextcloud/explicit-file-permissionsRoeland Jago Douma
Set umask before operations that create local files
2021-03-30gracefully handle deleteFromSelf when share is already goneArthur Schiwon
- handling race conditions Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2021-03-30Update Mink from 1.7.1 to 1.8.1 in acceptance testsDaniel Calviño Sánchez
Since version 1.8.0 of Mink "Mink::getSession()" no longer starts the session automatically (see https://github.com/minkphp/Mink/pull/705), so it now needs to be explicitly started. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-03-30Update Selenium driver for Mink from 1.3.1 to 1.4.0 in acceptance testsDaniel Calviño Sánchez
Since version 1.4.0 the Selenium driver for Mink uses again the element on which the value was set (see https://github.com/minkphp/MinkSelenium2Driver/pull/286). When creating a new folder or renaming one sending a new line ("\r") caused the element on which the value was set to be removed, so the element was no longer attached to the DOM when the driver tried to use it again, and thus a "StaleElementReference" exception was thrown. Due to this now it is needed to explicitly click the confirm button when creating a new folder. In the case of the renaming, on the other hand, nothing else besides not sending the new line is needed, as the Selenium driver now unfocuses the element (that is why it uses again the element after setting the value) which triggers the renaming. Besides that, the Selenium driver for Mink uses a library to simulate certain events, bitovi/syn. In version 1.4.0 that library was updated to version 0.0.3, which seems to somehow break pressing the "escape" key. Due to this now the sharing menu has to be closed by pressing "enter" on the share menu button instead. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-03-30Update Behat from 3.7.0 to 3.8.1 in acceptance testsDaniel Calviño Sánchez
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-03-30Update PHPUnit from 4.X to 6.X in acceptance testsDaniel Calviño Sánchez
The PHPUnit update also required an update of "symfony/yaml", so besides the changes needed for PHPUnit the "behat.yml" file also had to be adjusted. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2021-03-29Merge pull request #26353 from ↵Joas Schilling
nextcloud/techdebt/noid/make-testcase-class-compatible-with-phpunit-9.5 Make Testcase class compatible with phpunit-9.5
2021-03-29Make Testcase class compatible with phpunit-9.5Joas Schilling
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-03-26Add known user check in avatar when v2-private scopeVincent Petry
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-03-26Added PlaceholderAvatar with own cached imagesVincent Petry
When avatar scope is private, the PlaceholderAvatar is used to deliver a placeholder avatar based on the user's initials. This was implemented as a separate class for now to avoid messing with the existing UserAvatar implementation and its generated vs non-generated logic. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-03-26Add property scope tests for AccountManagerVincent Petry
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-03-26Map old account scope properties to new namesVincent Petry
Use new scope values in settings page. Adjust all consumers to use the new constants. Map old scope values to new ones in account property getter. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-03-26Add new v2-private account scopeVincent Petry
Added new v2-private account manager scope that restricts the scope further by excluding public link access. Avatars with v2-private account scope are now showing the guest avatar instead of the real avatar. Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2021-03-26Merge pull request #26281 from hosting-de/fix/emailRoeland Jago Douma
Change my email address
2021-03-25Cleanup unneeded code around database.xmlMorris Jobke
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2021-03-24Change my email addressJohannes Leuker
Signed-off-by: Johannes Leuker <j.leuker@hosting.de>
2021-03-24Fix language codes test result orderVincent Petry
Fixes issue with Oracle by enforcing the order of the results to check. Signed-off-by: Vincent Petry <vincent@nextcloud.com>