From d3b976bf364009c1c01f55c1068d16a446aaab91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=B4me=20Chilliet?= Date: Tue, 18 Mar 2025 11:56:36 +0100 Subject: [PATCH] feat: add integration test for sharing activity MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Côme Chilliet --- .github/workflows/integration-sqlite.yml | 9 +++++ .../sharing_features/sharing-activity.feature | 36 +++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 build/integration/sharing_features/sharing-activity.feature diff --git a/.github/workflows/integration-sqlite.yml b/.github/workflows/integration-sqlite.yml index ebffdd8a62b..3ce3830610f 100644 --- a/.github/workflows/integration-sqlite.yml +++ b/.github/workflows/integration-sqlite.yml @@ -73,6 +73,7 @@ jobs: php-versions: ['8.1'] spreed-versions: ['stable31'] + activity-versions: ['stable31'] services: redis: @@ -104,6 +105,14 @@ jobs: path: apps/spreed ref: ${{ matrix.spreed-versions }} + - name: Checkout Activity app + if: ${{ matrix.test-suite == 'sharing_features' }} + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 + with: + repository: nextcloud/activity + path: apps/activity + ref: ${{ matrix.activity-versions }} + - name: Set up php ${{ matrix.php-versions }} uses: shivammathur/setup-php@c541c155eee45413f5b09a52248675b1a2575231 #v2.31.1 with: diff --git a/build/integration/sharing_features/sharing-activity.feature b/build/integration/sharing_features/sharing-activity.feature new file mode 100644 index 00000000000..67f2d9fd79b --- /dev/null +++ b/build/integration/sharing_features/sharing-activity.feature @@ -0,0 +1,36 @@ +# SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors +# SPDX-License-Identifier: AGPL-3.0-or-later +Feature: sharing + Background: + Given using api version "1" + Given using new dav path + Given invoking occ with "app:enable --force activity" + Given the command was successful + Given user "user0" exists + And Logging in using web as "user0" + And Sending a "POST" to "/apps/activity/settings" with requesttoken + | public_links_notification | 1 | + | public_links_upload_email | 1 | + | notify_setting_batchtime | 0 | + | activity_digest | 0 | + + Scenario: Creating a new mail share + Given dummy mail server is listening + And As an "user0" + When creating a share with + | path | welcome.txt | + | shareType | 4 | + | shareWith | dumy@test.com | + Then the OCS status code should be "100" + And the HTTP status code should be "200" + And last share can be downloaded + + Scenario: Creating a new public share + Given user "user0" exists + And As an "user0" + When creating a share with + | path | welcome.txt | + | shareType | 3 | + Then the OCS status code should be "100" + And the HTTP status code should be "200" + And last link share can be downloaded