Commit Graph

4895 Commits

Author SHA1 Message Date
Robin Appelman 0625d2957c cleanup shared lock if changing to exclusive lock failed
Signed-off-by: Robin Appelman <robin@icewind.nl>
2019-01-22 15:13:40 +00:00
Roeland Jago Douma 16cca10b11
Fix template paramter
Else we get shown an error page instead of the correct 403.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2019-01-22 10:12:04 +01:00
Roeland Jago Douma 50ed420440
Merge pull request #13035 from nextcloud/objectstore-write-exists-14
[14] upload new files in objectstore to a .part path first
2019-01-14 11:29:52 +01:00
Bjoern Schiessle 5153c1b519 fix can change password check in case of encryption is enabled
Admin should _not_ be able to change password when:
- if an encryption module is loaded and it uses per-user keys
- if encryption is enabled but no encryption modules are loaded

Admin should be able to change the password when:
- no encryption module is loaded and encryption is disabled
- encryption module is loaded but it doesn't require per user keys

Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
2019-01-04 08:54:46 +00:00
Daniel Calviño Sánchez 0f3a0420f7 Add acceptance tests for opening search results for comments
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-12-24 13:22:06 +00:00
Daniel Calviño Sánchez aeb2760d7e Add acceptance tests for searching comments
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-12-24 13:22:06 +00:00
Roeland Jago Douma ce2c08da6a
Merge pull request #12617 from nextcloud/backport/10839/stable14
[stable14] adjust Calendar resource / room interfaces to use class implementation
2018-12-22 12:15:05 +01:00
Roeland Jago Douma 73f19a7a4c Use a case insensitive search for email
Fixes #7084
Now entering wrongly cased email (roeland@ instead of Roeland@) for
password reset etc. Will also work.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-12-20 15:19:28 +00:00
Robin Appelman 2c1ab34aca
upload new files in objectstore to a .part path first
Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-12-12 15:48:29 +01:00
Robin Appelman 601f35c337
Add objectExists to objectstore interface
Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-12-12 15:42:06 +01:00
Carsten Wiedmann 571e3c155c
Apply patch from @cwiedmann but drop -oi option for pipe
* Add sendmailmode to gui
* Add testcases for pipe mode

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2018-12-08 17:18:04 +01:00
Julius Härtl 72ab9edb8d
Make sure to always load the latest icons-vars.css file
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-12-07 23:30:28 +01:00
Daniel Calviño Sánchez edab262b0e Add acceptance tests for comments on shared files and folders
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-12-07 14:08:50 +00:00
Robin Appelman 7ee9781087 Fix folder path containing leading slash when getting mount root by id
This fixes collabora on public link shared groupfolders

Fixes https://github.com/nextcloud/groupfolders/issues/225

Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-11-28 19:07:51 +00:00
Daniel Kesselberg e1739e3da9
Merge pull request #12701 from nextcloud/stable14-12632-add-acceptance-tests-for-sharing-files-and-folders-with-another-user
[stable14] Add acceptance tests for sharing files and folders with another user
2018-11-28 14:11:55 +01:00
Daniel Calviño Sánchez 876ee0fd76 Wait for the comment to be added before changing to another file
If the server is too slow, changing to a different file immediately
after sending a new comment but without waiting for the comment to be
shown for the original file could cause the new comment to be shown for
the current file instead.

This is, indeed, a bug in the comments. However, it is not possible to
test it reliably in the acceptance tests, as it depends on how fast the
server adds the message and how fast the client changes to a different
file; sometimes the test would fail and sometimes it would not.

Therefore, now it is waited for the comment to be added before changing
to another file, as in this case it can be reliably tested that changing
to a different file does not cause the comments from the previous file
to be shown in the current file (this was a different bug already fixed
and due to which this test was added in the first place).

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-27 16:56:38 +00:00
Daniel Calviño Sánchez fc0a1d1015 Wait for the empty content element to be shown
When the "Comments" tab is open the empty content element is always in
the DOM, although it is only shown once the message collection was
fetched and there were no messages. Due to this it is necessary to
explicitly wait for it to be shown instead of relying on the implicit
wait made to find the element; otherwise it would be found immediately
and if the collection was not fetched yet it would not be visible,
causing the test to fail.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-27 16:56:38 +00:00
Daniel Calviño Sánchez c55054e2a5 Rename "FilesSharingAppContext" to "PublicShareContext"
Having both "FilesAppSharingContext" and "FilesSharingAppContext" was
confusing, so "FilesSharingAppContext" was renamed to a more descriptive
name.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:49 +01:00
Daniel Calviño Sánchez 6be19a5ca3 Extract locators and steps for sharing in Files app to their own context
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:49 +01:00
Daniel Calviño Sánchez 2af399f0ae Extract sharing related acceptance tests to their own feature files
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:49 +01:00
Daniel Calviño Sánchez fca154d1e0 Add acceptance tests for folders that can not be reshared
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:48 +01:00
Daniel Calviño Sánchez 708e40e303 Add acceptance tests for resharing a folder with another user
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:48 +01:00
Daniel Calviño Sánchez 792863ed10 Add acceptance test for checking that the owner can see reshares
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:48 +01:00
Daniel Calviño Sánchez fd4e10e056 Add acceptance test for resharing a file with another user
To reshare a file there must be at least three enabled users in the
system; although it would be possible to run the steps to create a third
user in the scenarios that need it for convenience a third enabled user
besides "admin" and "user0" was added to the default setup.

In a similar way, a new step was added too to login as a given user
name, similar to the steps to log in as "user0" and as "admin".

Finally, another actor, "Jim", was introduced for those scenarios which
should be played by three standard actors (that is, without a special
configuration like "Rubeus").

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:48 +01:00
Daniel Calviño Sánchez 2a27481e2f Add acceptance tests for sharing a folder with another user
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:48 +01:00
Daniel Calviño Sánchez 971c548256 Add acceptance tests for sharing a file with another user
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-23 15:14:43 +01:00
Georg Ehrke 92b264cc09 RoomManager/ResourceManager: Inject IServerContainer instead of using OC Server
Signed-off-by: Georg Ehrke <developer@georgehrke.com>
2018-11-22 22:41:29 +00:00
Georg Ehrke b0d17266e4 adjust Calendar resource / room interfaces to use class implementation
Signed-off-by: Georg Ehrke <developer@georgehrke.com>
2018-11-22 22:41:28 +00:00
Daniel Calviño Sánchez 2d58826d42 Add acceptance tests for showing again the input field for tags
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-22 17:43:58 +01:00
Daniel Calviño Sánchez f9efd31623 Add acceptance tests for opening and closing again the details view
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-22 17:43:58 +01:00
Daniel Calviño Sánchez 400d42a47a Add acceptance tests for marking a file as favorite in the details view
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-22 17:43:58 +01:00
Daniel Calviño Sánchez d0ea4ad8b8 Add acceptance tests for switching to the comments of another file
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-11-22 17:43:58 +01:00
Morris Jobke 511eade1d4
Use the proper default values
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2018-11-19 15:49:49 +01:00
Kyle Fazzari 5ba33b7574
Verify that isPhpMailerUsed uses config as expected
Signed-off-by: Kyle Fazzari <kyrofa@ubuntu.com>
2018-11-19 15:49:49 +01:00
Roeland Jago Douma 5678f432a4
Use the proper server for the apptoken flow login
If a user can't authenticate normally (because they have 2FA that is not
available on their devices for example). The redirect that is generated
should be of the proper format.

This means

1. Include the protocol
2. Include the possible subfolder

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-11-06 08:05:02 +01:00
Morris Jobke b292f919c6
Revert "Wait for cron to finish before running upgrade command"
This reverts commit 18e9631810.

Signed-off-by: Morris Jobke <hey@morrisjobke.de>
2018-11-01 22:09:45 +01:00
Roeland Jago Douma f171378837 Move ExpiredTokenException to the correct namespace
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-10-31 10:54:17 +01:00
Roeland Jago Douma 074672f8f2
Merge pull request #12121 from nextcloud/stable14-12104-move-acceptance-tests-that-crash-the-php-built-in-server-to-apache
[stable14] Move acceptance tests that crash the PHP built-in server to Apache
2018-10-29 19:18:53 +01:00
Daniel Calviño Sánchez 264421b5da Move the browser window of an actor to the foreground when acting as him
Each time a new actor appears in a scenario the browser window of the
new actor is put in front of the browser windows of the previous actors.
Before, when acting again as a previous actor his browser window stayed
in the background; in most cases everything worked fine even if the
window was in the background, but due to a bug in the Firefox driver of
Selenium and/or maybe in Firefox itself when the window was in the
background it was not possible to set the value of an input field that
had a range selected.

Now, when acting again as a previous actor his browser window is brought
to the foreground. This prevents the bug from manifesting, but also
reflects better how a user would interact with the browser in real life.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-10-29 16:26:12 +01:00
Daniel Calviño Sánchez 021c153886 Move acceptance tests that crash the PHP built-in server to Apache
The PHP built-in server can crash when certain actions are performed in
Nextcloud (but although the crash is triggered by Nextcloud it does not
seem to be a Nextcloud bug), which can lead to failures in the
acceptance tests that would have otherwise passed.

A crash of the PHP built-in server during an acceptance test can be
identified by the message "sh: 1: kill: No such process" in the
acceptance tests output; as the PHP built-in server crashed its process
does no longer exist when it is tried to be killed when the scenario
ends.

Although the crash has been observed in other tests too it is more
prevalent in the tests for tags and the theming app. In order to
reduce the false positives those tests are now run on Apache instead of
on the PHP built-in sever. However, the rest of tests are still run on
the PHP built-in server due to its lower resource consumption.

In order to run a feature or just a scenario using Apache it has to be
tagged with "@apache"; features or scenarios without that tag (the
default) will run on the PHP built-in server instead.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-10-29 16:23:38 +01:00
Daniel Calviño Sánchez b321e47e5d Link the default Apache directory to the Nextcloud server in all runners
In order to run the acceptance tests in Apache "/var/www/html" has to be
linked to the root directory of the Nextcloud server. Before this was
automatically done when launching the acceptance tests through
"./run.sh", but an explicit command was needed when run in Drone. Now
the linking was moved from "run.sh" to "run-local.sh", so it is
automatically done when run through "./run.sh" and in Drone, including
when running the tests for an app instead of for the server.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-10-29 16:23:38 +01:00
Daniel Calviño Sánchez 2bd81a2557 Extract acceptance tests for tags to their own feature file
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-10-29 16:23:38 +01:00
Bjoern Schiessle 6f3328a9cd
skip already decrypted files on decrypt all command
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
2018-10-25 17:52:51 +02:00
Morris Jobke 751aa99682
Merge pull request #12005 from iPaat/Backport14/Fix11847
[stable14] Remove cookies from Clear-Site-Data Header
2018-10-24 15:38:27 +02:00
Morris Jobke e5814bd948
Merge pull request #11800 from nextcloud/lookupserver-and-global-scale-stable14
[stable14] always query the lookup server in a global scale setup
2018-10-24 14:44:05 +02:00
Patrick Conrad bae4207246
Remove cookies from Clear-Site-Data Header
In 2f87fb6b45 this header was introduced. The referenced documentation says:

> When delivered with a response from https://example.com/clear, the following header will cause cookies associated with the origin https://example.com to be cleared, as well as cookies on any origin in the same registered domain (e.g. https://www.example.com/ and https://more.subdomains.example.com/).

This also applies if `https://nextcloud.example.com/` sends the `Clear-Site-Data: "cookies"` header.
This is not the behavior we want at this point!

So I removed the deletion of cookies from the header. This has no effect on the logout process as this header is supported only recently and the logout works in old browsers as well.

Signed-off-by: Patrick Conrad <conrad@iza.org>
(cherry picked from commit 1806baaeaf)
2018-10-24 08:50:26 +02:00
Daniel Calviño Sánchez c1e37bb387 Add acceptance tests for opening a section in the Files app
Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-10-23 16:44:29 +02:00
Georg Ehrke 554c80b403
filter null values for UserManager::getByEmail
Signed-off-by: Georg Ehrke <developer@georgehrke.com>
2018-10-22 15:51:57 +02:00
Bjoern Schiessle 49b98b52ce
add more tests
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
2018-10-12 16:13:57 +02:00
Bjoern Schiessle 84e39b522c
some small fixes and improvements
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
2018-10-10 16:08:49 +02:00