Commit Graph

42916 Commits

Author SHA1 Message Date
Daniel Calviño Sánchez fcd6cf08e0 Generalize file list steps so a specific ancestor can be used
The "FileListContext" provides steps to interact with and check the
behaviour of a file list. However, the "FileListContext" does not know
the right file list ancestor that has to be used by the file list steps,
so until now the file list steps were explicitly wired to the Files app
and they could be used only in that case.

Instead of duplicating the steps with a slightly different name (for
example, "I create a new folder named :folderName in the public shared
folder" instead of "I create a new folder named :folderName") the steps
were generalized; now contexts that "know" that certain file list
ancestor has to be used by the FileListContext steps performed by
certain actor from that point on (until changed again) set it
explicitly. For example, when the current page is the Files app then the
ancestor of the file list is the main view of the current section of the
Files app, but when the current page is a shared link then the ancestor
is set to null (because there will be just one file list, and thus its
ancestor is not relevant to differentiate between instances)

A helper trait, "FileListAncestorSetter", was introduced to reduce the
boilerplate needed to set the file list ancestor from other contexts.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-09 03:37:08 +01:00
Daniel Calviño Sánchez 766135cb64 Generalize file list locators so a specific ancestor can be used
The file list is used in other places besides the Files app (for
example, the File sharing app); in those cases the locators for the file
list elements are the same, but not for the ancestor of the file list.
To make possible to reuse the file list locators in those cases too now
they receive the ancestor to use.

Note that the locators for the file actions menu were not using an
ancestor locator because it is expected that there is only one file
actions menu at a time in the whole page; that may change in the future,
but for the time being it is a valid assumption and thus the ancestor
was not added to those locators in this commit.

Although the locators were generalized the steps themselves still use
the "FilesAppContext::currentSectionMainView" locator as ancestor; the
steps will be generalized in a following commit.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-09 03:37:08 +01:00
Daniel Calviño Sánchez 10490f2ac3 Store the name of the actor in the Actor object
This is needed to be able to easily use the actor as a key in an array.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-09 03:37:08 +01:00
Daniel Calviño Sánchez 49f2ba16f0 Extract file list locators and steps to its own class
Besides the extraction some minor adjustments (sorting locators for file
action menu entries to reflect the order of the menu entries in the UI,
moving parametrized locators like "createMenuItemFor" above the locators
that use them and placing "descendantOf" calls always in a new line)
were made too.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-09 03:37:08 +01:00
Nextcloud bot a20e9d7891
[tx-robot] updated from transifex 2018-03-09 01:12:12 +00:00
Roeland Jago Douma 1329061d31
Merge pull request #8648 from nextcloud/feature/csrf-token-controller
Use session heartbeat to update CSRF token
2018-03-08 21:15:24 +01:00
Roeland Jago Douma 7a7c350a2d
Merge pull request #8716 from nextcloud/fix-cache-prefixing
Remove base url from global cache prefix
2018-03-08 21:12:54 +01:00
Roeland Jago Douma 7e374200c4
Merge pull request #8575 from nextcloud/new-folder-button
Updated popover rules to allow form inputs and added input submit for…
2018-03-08 21:09:44 +01:00
Roeland Jago Douma 633d0581a3
Merge pull request #8728 from nextcloud/better-handling-of-invisible-elements-in-acceptance-tests
Better handling of invisible elements in acceptance tests
2018-03-08 21:04:20 +01:00
Roeland Jago Douma d05469959e
Merge pull request #8715 from nextcloud/objectstore-no-part-files
disable part files for object stores
2018-03-08 20:52:16 +01:00
rakekniven 1046fb5111
Update login.php
Fixed grammar issue.
Reported at Transifex. See https://www.transifex.com/nextcloud/nextcloud/translate/#af/$/124614533?issue=yes
2018-03-08 20:08:11 +01:00
Christoph Wurst b9720703e8 Add CSRF token controller to retrieve the current CSRF token
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2018-03-08 16:48:50 +01:00
Joas Schilling 882096653e
Fix calculation if there are more results
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-03-08 16:22:16 +01:00
Daniel Calviño Sánchez c1fa0f8b86 Add automatic handling of NoSuchElement exceptions
NoSuchElement exceptions are sometimes thrown instead of
StaleElementReference exceptions. This can happen when the Selenium2
driver for Mink performs an action on an element through the WebDriver
session instead of directly through the WebDriver element. In that case,
if the element with the given ID does not exist, a NoSuchElement
exception would be thrown instead of a StaleElementReference exception,
so those cases are handled like StaleElementReference exceptions.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-08 14:54:01 +01:00
Daniel Calviño Sánchez deb2495f89 Add automatic handling of MoveTargetOutOfBounds exceptions
MoveTargetOutOfBounds exceptions are sometimes thrown instead of
ElementNotVisible exceptions. This can happen when the Selenium2 driver
for Mink moves the cursor on an element using the "moveto" method of the
Webdriver session, for example, before clicking on an element. In that
case, if the element is not visible, "moveto" would throw a
MoveTargetOutOfBounds exception instead of an ElementNotVisible
exception, so those cases are handled like ElementNotVisible exceptions.

Note that MoveTargetOutOfBounds exceptions could be thrown too if the
element was visible but "out of reach"; there is no problem in handling
those cases as if the element was not visible, as the exception will be
thrown again anyway once it is verified that the element is indeed
visible.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2018-03-08 14:53:15 +01:00
Joas Schilling 3d7ae4aa97
Add tests for finding own email and user results pagination
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-03-08 13:26:26 +01:00
Morris Jobke cccf6f4d5f
Merge pull request #8221 from Cybso/8220_applyLdapUserFilter_on_members
Apply ldapUserFilter on members of group
2018-03-08 13:19:02 +01:00
Robin Appelman f5ef9e02b2
emit pre-hooks earlier when not using part files
Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-03-08 13:02:35 +01:00
Morris Jobke a2db959f5c
Merge pull request #8593 from eneiluj/master
Allow public page access to apps with group restrictions
2018-03-08 11:27:52 +01:00
Roeland Jago Douma 3ad7daeda5
Add tests
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-03-08 11:05:18 +01:00
John Molakvoæ (skjnldsv) cee5be6ff2
Fixed jsunit
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-08 10:31:33 +01:00
Roeland Jago Douma 340e8ef16c
Make SecurityMiddleware strict
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-03-08 10:11:47 +01:00
Morris Jobke 069e3f50a7
Merge pull request #8711 from nextcloud/objectstore-write-only-fopen
don't read existing file when overwriting using object store
2018-03-08 09:32:39 +01:00
Roeland Jago Douma af55b03386
Merge pull request #8662 from nextcloud/better-debugging-unit-tests
Better debugging for "Your test case is not allowed to access the dat…
2018-03-07 21:53:34 +01:00
John Molakvoæ (skjnldsv) 3ef4131533
Fixed event propagation on safari
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 17:10:46 +01:00
Joas Schilling 1dd40b1f45
Single quotes
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-03-07 16:50:18 +01:00
Joas Schilling 559978c50e
Suppress phan error
Signed-off-by: Joas Schilling <coding@schilljs.com>
2018-03-07 16:43:16 +01:00
John Molakvoæ (skjnldsv) e1ec4514cc
Use label for better focus on external share
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 15:28:03 +01:00
John Molakvoæ (skjnldsv) 5dbd09f07c
Align radio & checkboxes
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 15:17:54 +01:00
John Molakvoæ (skjnldsv) 446a3a9d5a
Fixed ext share style and use varable for popover height
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 15:12:06 +01:00
Julius Härtl 573b940761
Use cache prefix for theming as well
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-03-07 15:09:43 +01:00
Julius Härtl 95366bbd1f
Fix tests to use ICacheFactory
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-03-07 15:09:43 +01:00
Julius Härtl 63e261b444
Actually clear cache values for all base urls
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-03-07 15:09:43 +01:00
Julius Härtl f652c28b21
Use JSCombiner from server container when searching for JS files
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-03-07 15:09:43 +01:00
Julius Härtl 50a9beb4bb
Move base url from global cache prefix to frontend related ones
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2018-03-07 15:09:43 +01:00
Morris Jobke 8d865483f4
Merge pull request #8714 from nextcloud/8705
Check if the cached js file exists
2018-03-07 14:45:43 +01:00
Roeland Jago Douma 448a5e574e
Fix tests
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-03-07 14:04:21 +01:00
Robin Appelman fc35352122
disable part files for object stores
Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-03-07 13:33:35 +01:00
John Molakvoæ (skjnldsv) e2910e17b0
Default left margin for entries without icons
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:38 +01:00
John Molakvoæ (skjnldsv) e77bddf56b
Css hack to add margin on first or last visible inputs
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:38 +01:00
John Molakvoæ (skjnldsv) 966ceca8ea
Removed unwanted conflicting props
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:37 +01:00
John Molakvoæ (skjnldsv) 8d986160b8
Improved inline confirm icon with opacity and fixed ext share loading state
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:37 +01:00
John Molakvoæ (skjnldsv) 4e6043fd6b
Fixed tooltip positionning & error display
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:37 +01:00
John Molakvoæ (skjnldsv) 955c2ee1a7
PoC inline icon-confirm with inputs
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:37 +01:00
John Molakvoæ (skjnldsv) a7a3640224
fixup! Updated popover rules to allow form inputs and added input submit for new File
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:37 +01:00
John Molakvoæ (skjnldsv) 3964616a9e
Updated popover rules to allow form inputs and added input submit for new File
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
2018-03-07 13:17:36 +01:00
Roeland Jago Douma 34b86edc34
Check if the cached js file exists
Fixes #8705

If the file does not exist (for whatever reason). It is never cached. No
matter what the depscache etc tell you.

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
2018-03-07 12:55:05 +01:00
Morris Jobke d1aa96fef9
Merge pull request #8373 from nextcloud/right-header-stdrd
New standard for top right header
2018-03-07 12:33:11 +01:00
Roland Tapken 2472b93fd9 dn2ocname: also apply group filter to readAttribute()
Signed-off-by: Roland Tapken <roland@bitarbeiter.net>
2018-03-07 12:18:46 +01:00
Robin Appelman 9764e70494
don't read existing file when overwriting using object store
Signed-off-by: Robin Appelman <robin@icewind.nl>
2018-03-07 12:05:57 +01:00