app-files-sharing-link.feature 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149
  1. Feature: app-files-sharing-link
  2. Scenario: open the menu in a public shared link
  3. Given I act as John
  4. And I am logged in
  5. And I share the link for "welcome.txt"
  6. And I write down the shared link
  7. When I act as Jane
  8. And I visit the shared link I wrote down
  9. And I see that the current page is the shared link I wrote down
  10. And I open the Share menu
  11. Then I see that the Share menu is shown
  12. Scenario: hide download in a public shared link
  13. Given I act as John
  14. And I am logged in
  15. And I share the link for "welcome.txt"
  16. And I set the download of the shared link as hidden
  17. And I write down the shared link
  18. When I act as Jane
  19. And I visit the shared link I wrote down
  20. And I see that the current page is the shared link I wrote down
  21. Then I see that the download button is not shown
  22. And I see that the Share menu button is not shown
  23. Scenario: show download again in a public shared link
  24. Given I act as John
  25. And I am logged in
  26. And I share the link for "welcome.txt"
  27. And I set the download of the shared link as hidden
  28. And I set the download of the shared link as shown
  29. And I write down the shared link
  30. When I act as Jane
  31. And I visit the shared link I wrote down
  32. And I see that the current page is the shared link I wrote down
  33. Then I see that the download button is shown
  34. And I open the Share menu
  35. And I see that the Share menu is shown
  36. Scenario: creation is not possible by default in a public shared folder
  37. Given I act as John
  38. And I am logged in
  39. And I create a new folder named "Shared folder"
  40. # To share the link the "Share" inline action has to be clicked but, as the
  41. # details view is opened automatically when the folder is created, clicking
  42. # on the inline action could fail if it is covered by the details view due
  43. # to its opening animation. Instead of ensuring that the animations of the
  44. # contents and the details view have both finished it is easier to close the
  45. # details view and wait until it is closed before continuing.
  46. And I close the details view
  47. And I see that the details view is closed
  48. And I share the link for "Shared folder"
  49. And I write down the shared link
  50. When I act as Jane
  51. And I visit the shared link I wrote down
  52. And I see that the current page is the shared link I wrote down
  53. And I see that the file list is eventually loaded
  54. Then I see that it is not possible to create new files
  55. Scenario: create folder in a public editable shared folder
  56. Given I act as John
  57. And I am logged in
  58. And I create a new folder named "Editable shared folder"
  59. # To share the link the "Share" inline action has to be clicked but, as the
  60. # details view is opened automatically when the folder is created, clicking
  61. # on the inline action could fail if it is covered by the details view due
  62. # to its opening animation. Instead of ensuring that the animations of the
  63. # contents and the details view have both finished it is easier to close the
  64. # details view and wait until it is closed before continuing.
  65. And I close the details view
  66. And I see that the details view is closed
  67. And I share the link for "Editable shared folder"
  68. And I set the shared link as editable
  69. And I write down the shared link
  70. When I act as Jane
  71. And I visit the shared link I wrote down
  72. And I see that the current page is the shared link I wrote down
  73. And I create a new folder named "Subfolder"
  74. Then I see that the file list contains a file named "Subfolder"
  75. Scenario: owner sees folder created in the public page of an editable shared folder
  76. Given I act as John
  77. And I am logged in
  78. And I create a new folder named "Editable shared folder"
  79. # To share the link the "Share" inline action has to be clicked but, as the
  80. # details view is opened automatically when the folder is created, clicking
  81. # on the inline action could fail if it is covered by the details view due
  82. # to its opening animation. Instead of ensuring that the animations of the
  83. # contents and the details view have both finished it is easier to close the
  84. # details view and wait until it is closed before continuing.
  85. And I close the details view
  86. And I see that the details view is closed
  87. And I share the link for "Editable shared folder"
  88. And I set the shared link as editable
  89. And I write down the shared link
  90. And I act as Jane
  91. And I visit the shared link I wrote down
  92. And I see that the current page is the shared link I wrote down
  93. And I create a new folder named "Subfolder"
  94. And I see that the file list contains a file named "Subfolder"
  95. When I act as John
  96. And I enter in the folder named "Editable shared folder"
  97. Then I see that the file list contains a file named "Subfolder"
  98. Scenario: set a password to a shared link
  99. Given I am logged in
  100. And I share the link for "welcome.txt"
  101. When I protect the shared link with the password "abcdef"
  102. Then I see that the working icon for password protect is shown
  103. And I see that the working icon for password protect is eventually not shown
  104. And I see that the link share is password protected
  105. # As Talk is not enabled in the acceptance tests of the server the checkbox
  106. # is never shown.
  107. And I see that the checkbox to protect the password of the link share by Talk is not shown
  108. Scenario: access a shared link protected by password with a valid password
  109. Given I act as John
  110. And I am logged in
  111. And I share the link for "welcome.txt" protected by the password "abcdef"
  112. And I write down the shared link
  113. When I act as Jane
  114. And I visit the shared link I wrote down
  115. And I see that the current page is the Authenticate page for the shared link I wrote down
  116. And I authenticate with password "abcdef"
  117. Then I see that the current page is the shared link I wrote down
  118. And I see that the shared file preview shows the text "Welcome to your Nextcloud account!"
  119. Scenario: access a shared link protected by password with an invalid password
  120. Given I act as John
  121. And I am logged in
  122. And I share the link for "welcome.txt" protected by the password "abcdef"
  123. And I write down the shared link
  124. When I act as Jane
  125. And I visit the shared link I wrote down
  126. And I authenticate with password "fedcba"
  127. Then I see that the current page is the Authenticate page for the shared link I wrote down
  128. And I see that a wrong password for the shared file message is shown
  129. Scenario: access a direct download shared link protected by password with a valid password
  130. Given I act as John
  131. And I am logged in
  132. And I share the link for "welcome.txt" protected by the password "abcdef"
  133. And I write down the shared link
  134. When I act as Jane
  135. And I visit the direct download shared link I wrote down
  136. And I see that the current page is the Authenticate page for the direct download shared link I wrote down
  137. And I authenticate with password "abcdef"
  138. # download starts no page redirection
  139. And I see that the current page is the Authenticate page for the direct download shared link I wrote down