Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

catch notfound and forbidden exception in smb::getmetadata #25659

Merged
merged 1 commit into from
Mar 5, 2021

Conversation

icewind1991
Copy link
Member

Handle those errors during scanning as files that don'

@icewind1991 icewind1991 added the 3. to review Waiting for reviews label Feb 15, 2021
@icewind1991 icewind1991 added this to the Nextcloud 22 milestone Feb 15, 2021
Copy link
Member

@rullzer rullzer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

psalm says no

@icewind1991 icewind1991 force-pushed the smb-getmetadata-catch branch 2 times, most recently from ea3ce59 to a1a987f Compare February 16, 2021 13:17
@icewind1991
Copy link
Member Author

made psalm happy

@faily-bot
Copy link

faily-bot bot commented Feb 16, 2021

🤖 beep boop beep 🤖

Here are the logs for the failed build:

Status of 2337: failure

acceptance-app-files-sharing

  • failure block could not be found - most likely this run got canceled
Show full log
+ tests/acceptance/run-local.sh --timeout-multiplier 10 --nextcloud-server-domain acceptance-app-files-sharing --selenium-server selenium:4444 allow-git-repository-modifications features/app-files-sharing.feature
Do not run Composer as root/super user! See https://getcomposer.org/root for details
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Package operations: 48 installs, 0 updates, 0 removals
  - Installing behat/gherkin (v4.6.2): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/polyfill-ctype (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (85%)�����������������Downloading (100%)
  - Installing symfony/filesystem (v5.2.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (65%)�����������������Downloading (75%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/config (v4.4.18): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/css-selector (v3.4.47): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing behat/mink (v1.7.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/yaml (v3.4.47): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/translation-contracts (v2.3.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (65%)�����������������Downloading (100%)
  - Installing symfony/polyfill-mbstring (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (100%)
  - Installing symfony/translation (v4.4.18): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/polyfill-php80 (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing psr/event-dispatcher (1.0.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing symfony/event-dispatcher-contracts (v2.2.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (85%)�����������������Downloading (100%)
  - Installing symfony/deprecation-contracts (v2.2.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing symfony/event-dispatcher (v5.2.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (55%)�����������������Downloading (70%)�����������������Downloading (100%)
  - Installing psr/container (1.0.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (75%)�����������������Downloading (100%)
  - Installing symfony/service-contracts (v2.2.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing symfony/dependency-injection (v4.4.18): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/polyfill-intl-normalizer (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (10%)�����������������Downloading (35%)�����������������Downloading (45%)�����������������Downloading (70%)�����������������Downloading (80%)�����������������Downloading (100%)
  - Installing symfony/polyfill-intl-grapheme (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing symfony/string (v5.2.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (10%)�����������������Downloading (20%)�����������������Downloading (65%)�����������������Downloading (75%)�����������������Downloading (85%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing symfony/polyfill-php73 (v1.22.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (65%)�����������������Downloading (100%)
  - Installing symfony/console (v5.2.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing behat/transliterator (v1.3.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing behat/behat (v3.7.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing behat/mink-extension (2.3.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (15%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing instaclick/php-webdriver (1.4.7): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (100%)
  - Installing behat/mink-selenium2-driver (v1.3.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (40%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (100%)
  - Installing webmozart/assert (1.9.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (0%)����������������Downloading (40%)�����������������Downloading (65%)�����������������Downloading (100%)
  - Installing phpdocumentor/reflection-common (2.2.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (50%)�����������������Downloading (100%)
  - Installing phpdocumentor/type-resolver (1.4.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (15%)�����������������Downloading (30%)�����������������Downloading (65%)�����������������Downloading (80%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing phpdocumentor/reflection-docblock (5.2.2): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (100%)
  - Installing phpunit/php-token-stream (1.4.12): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (100%)
  - Installing sebastian/version (1.0.6): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing sebastian/global-state (1.1.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (40%)�����������������Downloading (80%)�����������������Downloading (100%)
  - Installing sebastian/recursion-context (1.0.5): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (35%)�����������������Downloading (70%)�����������������Downloading (100%)
  - Installing sebastian/exporter (1.2.2): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing sebastian/environment (1.3.8): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (15%)�����������������Downloading (30%)�����������������Downloading (45%)�����������������Downloading (60%)�����������������Downloading (75%)�����������������Downloading (100%)
  - Installing sebastian/diff (1.4.3): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (75%)�����������������Downloading (100%)
  - Installing sebastian/comparator (1.2.4): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (10%)�����������������Downloading (55%)�����������������Downloading (65%)�����������������Downloading (75%)�����������������Downloading (85%)�����������������Downloading (100%)
  - Installing phpunit/php-text-template (1.2.1): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (35%)�����������������Downloading (100%)
  - Installing doctrine/instantiator (1.4.0): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (25%)�����������������Downloading (85%)�����������������Downloading (100%)
  - Installing phpunit/phpunit-mock-objects (2.3.8): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing phpunit/php-timer (1.0.9): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (45%)�����������������Downloading (100%)
  - Installing phpunit/php-file-iterator (1.4.5): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (100%)
  - Installing phpunit/php-code-coverage (2.2.4): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
  - Installing phpspec/prophecy (v1.10.3): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (45%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (80%)�����������������Downloading (90%)�����������������Downloading (100%)
  - Installing phpunit/phpunit (4.8.36): Downloading (connecting...)���������������������������Downloading (0%)           ���������������������������Downloading (5%)����������������Downloading (10%)�����������������Downloading (15%)�����������������Downloading (20%)�����������������Downloading (25%)�����������������Downloading (30%)�����������������Downloading (35%)�����������������Downloading (40%)�����������������Downloading (45%)�����������������Downloading (50%)�����������������Downloading (55%)�����������������Downloading (60%)�����������������Downloading (65%)�����������������Downloading (70%)�����������������Downloading (75%)�����������������Downloading (80%)�����������������Downloading (85%)�����������������Downloading (90%)�����������������Downloading (95%)�����������������Downloading (100%)
behat/mink suggests installing behat/mink-browserkit-driver (extremely fast headless driver for Symfony\Kernel-based apps (Sf2, Silex))
behat/mink suggests installing behat/mink-goutte-driver (fast headless driver for any app without JS emulation)
behat/mink suggests installing behat/mink-zombie-driver (fast and JS-enabled headless driver for any app (requires node.js))
symfony/event-dispatcher suggests installing symfony/http-kernel ()
symfony/dependency-injection suggests installing symfony/expression-language (For using expressions in service container configuration)
symfony/dependency-injection suggests installing symfony/finder (For using double-star glob patterns or when GLOB_BRACE portability is required)
symfony/dependency-injection suggests installing symfony/proxy-manager-bridge (Generate service proxies to lazy load them)
symfony/console suggests installing psr/log (For using the console logger)
symfony/console suggests installing symfony/lock ()
symfony/console suggests installing symfony/process ()
sebastian/global-state suggests installing ext-uopz (*)
phpunit/phpunit-mock-objects suggests installing ext-soap (*)
phpunit/php-code-coverage suggests installing ext-xdebug (>=2.2.1)
phpunit/phpunit suggests installing phpunit/php-invoker (~1.1)
Package phpunit/php-token-stream is abandoned, you should avoid using it. No replacement was suggested.
Package phpunit/phpunit-mock-objects is abandoned, you should avoid using it. No replacement was suggested.
Generating autoload files
Cloning into 'notifications'...
Installing and configuring Nextcloud server
Nextcloud was successfully installed
The user "user0" was created successfully
The user "user1" was created successfully
The user "disabledUser" was created successfully
The specified user is disabled
dashboard 7.1.0 disabled
System config value trusted_domains => 0 set to string acceptance-app-files-sharing
Saving the default state so acceptance tests can reset to it
Waiting for Selenium
Feature: app-files-sharing

  Scenario: share a file with another user                                    # /drone/src/tests/acceptance/features/app-files-sharing.feature:3
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I act as John                                                         # ActorContext::iActAs()
    And I rename "welcome.txt" to "farewell.txt"                              # FileListContext::iRenameTo()
    And I see that the file list contains a file named "farewell.txt"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I share "farewell.txt" with "user0"                                  # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "farewell.txt"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "farewell.txt"                            # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: share a file with another user that needs to accept shares        # /drone/src/tests/acceptance/features/app-files-sharing.feature:23
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I visit the settings page                                             # SettingsMenuContext::iVisitTheSettingsPage()
    And I open the "Sharing" section                                          # AppNavigationContext::iOpenTheSection()
    And I disable accepting the shares by default                             # SettingsContext::iDisableAcceptingTheSharesByDefault()
    And I see that shares are not accepted by default                         # SettingsContext::iSeeThatSharesAreNotAcceptedByDefault()
    And I act as John                                                         # ActorContext::iActAs()
    And I rename "welcome.txt" to "farewell.txt"                              # FileListContext::iRenameTo()
    And I see that the file list contains a file named "farewell.txt"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I share "farewell.txt" with "user0"                                  # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    And I see that the file list does not contain a file named "farewell.txt" # FileListContext::iSeeThatTheFileListDoesNotContainAFileNamed()
    And I accept the share for "/farewell.txt" in the notifications           # NotificationsContext::iAcceptTheShareForInTheNotifications()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "farewell.txt"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "farewell.txt"                            # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: share a file with another user who already has a file with that name # /drone/src/tests/acceptance/features/app-files-sharing.feature:50
    Given I act as John                                                          # ActorContext::iActAs()
    And I am logged in as the admin                                              # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                            # ActorContext::iActAs()
    And I am logged in                                                           # LoginPageContext::iAmLoggedIn()
    And I act as John                                                            # ActorContext::iActAs()
    When I share "welcome.txt" with "user0"                                      # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                               # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                            # ActorContext::iActAs()
    And I open the Files app                                                     # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "welcome (2).txt"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "welcome (2).txt"                            # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                      # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                             # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded    # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                         # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: share a skeleton file with another user before first login        # /drone/src/tests/acceptance/features/app-files-sharing.feature:68
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    When I share "welcome.txt" with "user0"                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    Then I see that the file list contains a file named "welcome.txt"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "welcome.txt"                             # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: reshare a file with another user                                  # /drone/src/tests/acceptance/features/app-files-sharing.feature:86
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I act as Jim                                                          # ActorContext::iActAs()
    And I am logged in as "user1"                                             # LoginPageContext::iAmLoggedInAs()
    And I act as John                                                         # ActorContext::iActAs()
    And I rename "welcome.txt" to "farewell.txt"                              # FileListContext::iRenameTo()
    And I see that the file list contains a file named "farewell.txt"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "farewell.txt" with "user0"                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    When I share "farewell.txt" with "user1"                                  # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user1"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jim                                                          # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "farewell.txt"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "farewell.txt"                            # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "user0"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: owner sees reshares with other users                              # /drone/src/tests/acceptance/features/app-files-sharing.feature:113
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I act as John                                                         # ActorContext::iActAs()
    And I rename "welcome.txt" to "farewell.txt"                              # FileListContext::iRenameTo()
    And I see that the file list contains a file named "farewell.txt"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "farewell.txt" with "user0"                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    And I share "farewell.txt" with "user1"                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user1"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    When I act as John                                                        # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    And I open the details view for "farewell.txt"                            # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    Then I see that the file is shared with "user0"                           # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I see that the file is shared with "user1"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()

  Scenario: share an empty folder with another user                           # /drone/src/tests/acceptance/features/app-files-sharing.feature:138
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I act as John                                                         # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                           # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I share "Shared folder" with "user0"                                 # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "Shared folder"       # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "Shared folder"                           # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()

  Scenario: sharee sees a folder created by the owner in a shared folder # /drone/src/tests/acceptance/features/app-files-sharing.feature:158
    Given I act as John                                                  # ActorContext::iActAs()
    And I am logged in as the admin                                      # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                    # ActorContext::iActAs()
    And I am logged in                                                   # LoginPageContext::iAmLoggedIn()
    And I act as John                                                    # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                      # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"   # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                             # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                       # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I enter in the folder named "Shared folder"                      # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                          # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"       # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as Jane                                                   # ActorContext::iActAs()
    And I open the Files app                                             # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                      # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"      # FileListContext::iSeeThatTheFileListContainsAFileNamed()

  Scenario: owner sees a folder created by the sharee in a shared folder # /drone/src/tests/acceptance/features/app-files-sharing.feature:177
    Given I act as John                                                  # ActorContext::iActAs()
    And I am logged in as the admin                                      # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                    # ActorContext::iActAs()
    And I am logged in                                                   # LoginPageContext::iAmLoggedIn()
    And I act as John                                                    # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                      # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"   # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                             # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                       # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                    # ActorContext::iActAs()
    And I open the Files app                                             # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                      # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                          # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"       # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as John                                                   # ActorContext::iActAs()
    And I enter in the folder named "Shared folder"                      # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"      # FileListContext::iSeeThatTheFileListContainsAFileNamed()

  Scenario: resharee sees a folder created by the owner in a shared folder # /drone/src/tests/acceptance/features/app-files-sharing.feature:197
    Given I act as John                                                    # ActorContext::iActAs()
    And I am logged in as the admin                                        # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                      # ActorContext::iActAs()
    And I am logged in                                                     # LoginPageContext::iAmLoggedIn()
    And I act as Jim                                                       # ActorContext::iActAs()
    And I am logged in as "user1"                                          # LoginPageContext::iAmLoggedInAs()
    And I act as John                                                      # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                        # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"     # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                               # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                         # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                      # ActorContext::iActAs()
    And I open the Files app                                               # FilesAppContext::iOpenTheFilesApp()
    And I share "Shared folder" with "user1"                               # FilesAppSharingContext::iShareWith()
    And I act as John                                                      # ActorContext::iActAs()
    And I enter in the folder named "Shared folder"                        # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                            # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as Jim                                                      # ActorContext::iActAs()
    And I open the Files app                                               # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                        # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()

  Scenario: owner sees a folder created by the resharee in a shared folder # /drone/src/tests/acceptance/features/app-files-sharing.feature:223
    Given I act as John                                                    # ActorContext::iActAs()
    And I am logged in as the admin                                        # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                      # ActorContext::iActAs()
    And I am logged in                                                     # LoginPageContext::iAmLoggedIn()
    And I act as Jim                                                       # ActorContext::iActAs()
    And I am logged in as "user1"                                          # LoginPageContext::iAmLoggedInAs()
    And I act as John                                                      # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                        # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"     # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                               # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                         # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                      # ActorContext::iActAs()
    And I open the Files app                                               # FilesAppContext::iOpenTheFilesApp()
    And I share "Shared folder" with "user1"                               # FilesAppSharingContext::iShareWith()
    And I act as Jim                                                       # ActorContext::iActAs()
    And I open the Files app                                               # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                        # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                            # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as John                                                     # ActorContext::iActAs()
    And I enter in the folder named "Shared folder"                        # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()

  Scenario: sharer does not see resharing option for a folder if resharing is disabled in the settings after the share is created # /drone/src/tests/acceptance/features/app-files-sharing.feature:249
    Given I am logged in as the admin                                                                                             # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I create a new folder named "Shared folder"                                                                               # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                                                            # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                                                      # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                                                                # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    When I visit the settings page                                                                                                # SettingsMenuContext::iVisitTheSettingsPage()
    And I open the "Sharing" section of the "Administration" group                                                                # AppNavigationContext::iOpenTheSectionOf()
    And I disable resharing                                                                                                       # SettingsContext::iDisableResharing()
    And I see that resharing is disabled                                                                                          # SettingsContext::iSeeThatResharingIsDisabled()
    Then I open the Files app                                                                                                     # FilesAppContext::iOpenTheFilesApp()
    And I open the details view for "Shared folder"                                                                               # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                                                                       # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                                                                              # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded                                                     # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that resharing for "user0" is not available                                                                         # FilesAppSharingContext::iSeeThatResharingForIsNotAvailable()

  Scenario: sharee can not reshare a folder if resharing is disabled in the settings after the share is created # /drone/src/tests/acceptance/features/app-files-sharing.feature:266
    Given I act as John                                                                                         # ActorContext::iActAs()
    And I am logged in as the admin                                                                             # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                                           # ActorContext::iActAs()
    And I am logged in                                                                                          # LoginPageContext::iAmLoggedIn()
    And I act as John                                                                                           # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                                                             # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                                          # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                                    # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                                              # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I visit the settings page                                                                               # SettingsMenuContext::iVisitTheSettingsPage()
    And I open the "Sharing" section of the "Administration" group                                              # AppNavigationContext::iOpenTheSectionOf()
    And I disable resharing                                                                                     # SettingsContext::iDisableResharing()
    And I see that resharing is disabled                                                                        # SettingsContext::iSeeThatResharingIsDisabled()
    When I act as Jane                                                                                          # ActorContext::iActAs()
    And I open the Files app                                                                                    # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "Shared folder"                                         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "Shared folder"                                                             # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                                                     # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                                                            # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded                                   # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                                                        # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()
    And I see that resharing the file is not allowed                                                            # FilesAppSharingContext::iSeeThatResharingTheFileIsNotAllowed()

  Scenario: sharee can unshare a folder if resharing is disabled in the settings after the share is created # /drone/src/tests/acceptance/features/app-files-sharing.feature:291
    Given I act as John                                                                                     # ActorContext::iActAs()
    And I am logged in as the admin                                                                         # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                                       # ActorContext::iActAs()
    And I am logged in                                                                                      # LoginPageContext::iAmLoggedIn()
    And I act as John                                                                                       # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                                                         # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                                      # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                                # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                                          # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                                                       # ActorContext::iActAs()
    And I open the Files app                                                                                # FilesAppContext::iOpenTheFilesApp()
    And I share "Shared folder" with "user1"                                                                # FilesAppSharingContext::iShareWith()
    And I act as John                                                                                       # ActorContext::iActAs()
    And I visit the settings page                                                                           # SettingsMenuContext::iVisitTheSettingsPage()
    And I open the "Sharing" section of the "Administration" group                                          # AppNavigationContext::iOpenTheSectionOf()
    And I disable resharing                                                                                 # SettingsContext::iDisableResharing()
    And I see that resharing is disabled                                                                    # SettingsContext::iSeeThatResharingIsDisabled()
    When I act as Jane                                                                                      # ActorContext::iActAs()
    And I open the Files app                                                                                # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "Shared folder"                                     # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "Shared folder"                                                         # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                                                 # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                                                        # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded                               # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                                                    # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()
    And I unshare the share with "user1"                                                                    # FilesAppSharingContext::iUnshareTheFileWith()
    And I see that the file is not shared with "user1"                                                      # FilesAppSharingContext::iSeeThatTheFileIsNotSharedWith()

  Scenario: resharee sees a folder created by the owner in a shared folder if resharing is disabled in the settings after the share is created # /drone/src/tests/acceptance/features/app-files-sharing.feature:322
    Given I act as John                                                                                                                        # ActorContext::iActAs()
    And I am logged in as the admin                                                                                                            # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                                                                          # ActorContext::iActAs()
    And I am logged in                                                                                                                         # LoginPageContext::iAmLoggedIn()
    And I act as Jim                                                                                                                           # ActorContext::iActAs()
    And I am logged in as "user1"                                                                                                              # LoginPageContext::iAmLoggedInAs()
    And I act as John                                                                                                                          # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                                                                                            # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                                                                         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                                                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                                                                             # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I act as Jane                                                                                                                          # ActorContext::iActAs()
    And I open the Files app                                                                                                                   # FilesAppContext::iOpenTheFilesApp()
    And I share "Shared folder" with "user1"                                                                                                   # FilesAppSharingContext::iShareWith()
    And I act as John                                                                                                                          # ActorContext::iActAs()
    And I visit the settings page                                                                                                              # SettingsMenuContext::iVisitTheSettingsPage()
    And I open the "Sharing" section of the "Administration" group                                                                             # AppNavigationContext::iOpenTheSectionOf()
    And I disable resharing                                                                                                                    # SettingsContext::iDisableResharing()
    And I see that resharing is disabled                                                                                                       # SettingsContext::iSeeThatResharingIsDisabled()
    And I open the Files app                                                                                                                   # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                                                                                            # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                                                                                                # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"                                                                             # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as Jim                                                                                                                          # ActorContext::iActAs()
    And I open the Files app                                                                                                                   # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                                                                                            # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"                                                                            # FileListContext::iSeeThatTheFileListContainsAFileNamed()

  Scenario: sharee can not reshare a folder if the sharer disables it         # /drone/src/tests/acceptance/features/app-files-sharing.feature:353
    Given I act as John                                                       # ActorContext::iActAs()
    And I am logged in as the admin                                           # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                         # ActorContext::iActAs()
    And I am logged in                                                        # LoginPageContext::iAmLoggedIn()
    And I act as John                                                         # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                           # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"        # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                  # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                            # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I set the share with "user0" as not reshareable                       # FilesAppSharingContext::iSetTheShareWithAsNotReshareable()
    And I see that "user0" can not reshare the share                          # FilesAppSharingContext::iSeeThatCanNotReshareTheShare()
    When I act as Jane                                                        # ActorContext::iActAs()
    And I open the Files app                                                  # FilesAppContext::iOpenTheFilesApp()
    Then I see that the file list contains a file named "Shared folder"       # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "Shared folder"                           # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                   # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                          # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that the file is shared with me by "admin"                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWithMeBy()
    And I see that resharing the file is not allowed                          # FilesAppSharingContext::iSeeThatResharingTheFileIsNotAllowed()

  Scenario: sharee can not reshare a subfolder if the sharer disables it for the parent folder # /drone/src/tests/acceptance/features/app-files-sharing.feature:376
    Given I act as John                                                                        # ActorContext::iActAs()
    And I am logged in as the admin                                                            # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                          # ActorContext::iActAs()
    And I am logged in                                                                         # LoginPageContext::iAmLoggedIn()
    And I act as John                                                                          # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                                            # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                         # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                   # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                             # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I set the share with "user0" as not reshareable                                        # FilesAppSharingContext::iSetTheShareWithAsNotReshareable()
    And I see that "user0" can not reshare the share                                           # FilesAppSharingContext::iSeeThatCanNotReshareTheShare()
    And I enter in the folder named "Shared folder"                                            # FileListContext::iEnterInTheFolderNamed()
    And I create a new folder named "Subfolder"                                                # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Subfolder"                             # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    When I act as Jane                                                                         # ActorContext::iActAs()
    And I open the Files app                                                                   # FilesAppContext::iOpenTheFilesApp()
    And I enter in the folder named "Shared folder"                                            # FileListContext::iEnterInTheFolderNamed()
    Then I see that the file list contains a file named "Subfolder"                            # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I open the details view for "Subfolder"                                                # FileListContext::iOpenTheDetailsViewFor()
    And I see that the details view is open                                                    # FilesAppContext::iSeeThatTheDetailsViewIsOpen()
    And I open the "Sharing" tab in the details view                                           # FilesAppContext::iOpenTheTabInTheDetailsView()
    And I see that the "Sharing" tab in the details view is eventually loaded                  # FilesAppContext::iSeeThatTheTabInTheDetailsViewIsEventuallyLoaded()
    And I see that resharing the file is not allowed                                           # FilesAppSharingContext::iSeeThatResharingTheFileIsNotAllowed()
  │
  ╳  Could not close connection (Behat\Mink\Exception\DriverException)
  │
  └─ @AfterScenario # ActorContext::cleanUpSessions()

  Scenario: sharee can not reshare a file with edit permission if the sharer disables it # /drone/src/tests/acceptance/features/app-files-sharing.feature:402
    Given I act as John                                                                  # ActorContext::iActAs()
    And I am logged in as the admin                                                      # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                    # ActorContext::iActAs()
    And I am logged in                                                                   # LoginPageContext::iAmLoggedIn()
    And I act as John                                                                    # ActorContext::iActAs()
    And I rename "welcome.txt" to "farewell.txt"                                         # FileListContext::iRenameTo()
    And I see that the file list contains a file named "farewell.txt"                    # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "farewell.txt" with "user0"                                              # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                       # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I set the share with "user0" as not editable                                     # FilesAppSharingContext::iSetTheShareWithAsNotEditable()
    And I see that "user0" can not edit the share                                        # FilesAppSharingContext::iSeeThatCanNotEditTheShare()
    When I act as Jane                                                                   # ActorContext::iActAs()
    And I open the Files app                                                             # FilesAppContext::iOpenTheFilesApp()
    And I share "farewell.txt" with "user1"                                              # FilesAppSharingContext::iShareWith()
    Then I see that the file is shared with "user1"                                      # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I see that "user1" can not edit the share                                        # FilesAppSharingContext::iSeeThatCanNotEditTheShare()
    And I see that "user1" can not be allowed to edit the share                          # FilesAppSharingContext::iSeeThatCanNotBeAllowedToEditTheShare()

  Scenario: sharee can not reshare a folder with create permission if the sharer disables it # /drone/src/tests/acceptance/features/app-files-sharing.feature:422
    Given I act as John                                                                      # ActorContext::iActAs()
    And I am logged in as the admin                                                          # LoginPageContext::iAmLoggedInAsTheAdmin()
    And I act as Jane                                                                        # ActorContext::iActAs()
    And I am logged in                                                                       # LoginPageContext::iAmLoggedIn()
    And I act as John                                                                        # ActorContext::iActAs()
    And I create a new folder named "Shared folder"                                          # FileListContext::iCreateANewFolderNamed()
    And I see that the file list contains a file named "Shared folder"                       # FileListContext::iSeeThatTheFileListContainsAFileNamed()
    And I share "Shared folder" with "user0"                                                 # FilesAppSharingContext::iShareWith()
    And I see that the file is shared with "user0"                                           # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I set the share with "user0" as not creatable                                        # FilesAppSharingContext::iSetTheShareWithAsNotCreatable()
    And I see that "user0" can not create in the share                                       # FilesAppSharingContext::iSeeThatCanNotCreateInTheShare()
    When I act as Jane                                                                       # ActorContext::iActAs()
    And I open the Files app                                                                 # FilesAppContext::iOpenTheFilesApp()
    And I share "Shared folder" with "user1"                                                 # FilesAppSharingContext::iShareWith()
    Then I see that the file is shared with "user1"                                          # FilesAppSharingContext::iSeeThatTheFileIsSharedWith()
    And I see that "user1" can not create in the share                                       # FilesAppSharingContext::iSeeThatCanNotCreateInTheShare()
    And I see that "user1" can not be allowed to create in the share                         # FilesAppSharingContext::iSeeThatCanNotBeAllowedToCreateInTheShare()

19 scenarios (19 passed)
374 steps (374 passed)
27m48.67s (5.95Mb)

@icewind1991
Copy link
Member Author

/backport to stable21

@icewind1991
Copy link
Member Author

/backport to stable20

Signed-off-by: Robin Appelman <robin@icewind.nl>
@icewind1991
Copy link
Member Author

/backport to stable19

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants