Nextcloud 13RC4, error in logfile, triggered by "occ config:list":
Invalid argument supplied for foreach() at lib/private/AppConfig.php#297
PHP Undefined index: workflowengine at lib/private/AppConfig.php#297
Fix: Check if index exists in array before using it.
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 rename :fileName1 to :fileName2 in the public shared folder"
instead of "I rename :fileName1 to :fileName2") 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>
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>
Besides the extraction some minor adjustments (moving parametrized
locators like "fileActionsMenuItemFor" 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>