From 2ef416e89e845c52105f517b6dcb6468c21f7fa1 Mon Sep 17 00:00:00 2001 From: Viktor Scharf Date: Fri, 4 Oct 2024 08:23:34 +0200 Subject: [PATCH] add tests to expected failures file --- tests/acceptance/bootstrap/SharingNgContext.php | 7 +++++-- .../expected-failures-localAPI-on-OCIS-storage.md | 13 +++++++++++-- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/tests/acceptance/bootstrap/SharingNgContext.php b/tests/acceptance/bootstrap/SharingNgContext.php index 80e7574b6fb..8e00d7cb3ba 100644 --- a/tests/acceptance/bootstrap/SharingNgContext.php +++ b/tests/acceptance/bootstrap/SharingNgContext.php @@ -282,8 +282,8 @@ public function sendShareInvitation(string $user, array $shareInfo, string $file $shareeId = ""; if ($shareType === "user") { $shareeId = $this->featureContext->getAttributeOfCreatedUser($sharee, 'id'); - if ($shareInfo['federatedServer']) { - $shareeId = base64_encode($shareeId . $shareInfo['federatedServer']); + if (isset($shareInfo['federatedServer'])) { + $shareeId = ($this->featureContext->ocmContext->getAcceptedUserByName($user, $sharee))['user_id']; } } elseif ($shareType === "group") { $shareeId = $this->featureContext->getAttributeOfCreatedGroup($sharee, 'id'); @@ -351,6 +351,9 @@ public function sendDriveShareInvitation(string $user, TableNode $table): Respon $shareeId = ""; if ($shareType === "user") { $shareeId = $this->featureContext->getAttributeOfCreatedUser($sharee, 'id'); + if (isset($shareInfo['federatedServer'])) { + $shareeId = ($this->featureContext->ocmContext->getAcceptedUserByName($user, $sharee))['user_id']; + } } elseif ($shareType === "group") { $shareeId = $this->featureContext->getAttributeOfCreatedGroup($sharee, 'id'); } diff --git a/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md b/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md index 1bcffbf70e2..ce88480b9f6 100644 --- a/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md +++ b/tests/acceptance/expected-failures-localAPI-on-OCIS-storage.md @@ -256,10 +256,19 @@ The expected failures in this file are from features in the owncloud/ocis repo. #### [OCM. admin cannot get federated users if he hasn't connection with them ](https://github.com/owncloud/ocis/issues/9829) -tests/acceptance/features/apiOcm/searchFederationUsers.feature - - [apiOcm/searchFederationUsers.feature:429](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiOcm/searchFederationUsers.feature#L429) - [apiOcm/searchFederationUsers.feature:601](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiOcm/searchFederationUsers.feature#L601) + +#### [OCM. federated connection is not dropped when one of the users deletes the connection](https://github.com/owncloud/ocis/issues/10216) + +- [apiOcm/deleteFederatedConnections.feature:39](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiOcm/deleteFederatedConnections.feature#L39) +- [apiOcm/deleteFederatedConnections.feature:66](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiOcm/deleteFederatedConnections.feature#L66) + + +#### [OCM. server crash after deleting share for ocm user](https://github.com/owncloud/ocis/issues/10213) + +- [apiOcm/deleteFederatedConnections.feature:103](https://github.com/owncloud/ocis/blob/master/tests/acceptance/features/apiOcm/deleteFederatedConnections.feature#L103) + Note: always have an empty line at the end of this file. The bash script that processes this file requires that the last line has a newline on the end.