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

fix(tests): Remove unstable sharing field from tests #14159

Merged
merged 1 commit into from
Jan 20, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions tests/integration/features/bootstrap/SharingContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -614,6 +614,19 @@ public function shareXIsReturnedWith(int $number, TableNode $body) {
$defaultExpectedFields['share_with_link'] = 'URL';
}

if (isset($fields['share_type']) && ($fields['share_type'] === '0' || $fields['share_type'] === '1')) {
/**
* This field was changed so often in the server,
* that we simply don't care any more. We want to test Talk,
* not normal user shares.
* Refs:
* - https://github.com/nextcloud/server/pull/49898
* - https://github.com/nextcloud/server/pull/48381
* - https://github.com/nextcloud/spreed/pull/13632
*/
unset($defaultExpectedFields['mail_send']);
}

$expectedFields = array_merge($defaultExpectedFields, $fields);

if (!array_key_exists('uid_file_owner', $expectedFields) &&
Expand Down
2 changes: 0 additions & 2 deletions tests/integration/features/sharing-1/create.feature
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,6 @@ Feature: create
And share is returned with
| permissions | 1 |
| share_type | 0 |
| mail_send | 0 |
And user "participant1" accepts last share
When user "participant1" shares "welcome (2).txt" with room "group room"
Then the OCS status code should be "404"
Expand Down Expand Up @@ -738,7 +737,6 @@ Feature: create
| share_with | participant2 |
| share_with_displayname | participant2-displayname |
| share_type | 0 |
| mail_send | 0 |
And user "participant2" gets all received shares
And the list of returned shares has 2 shares
And share 0 is returned with
Expand Down
Loading