From 55856cb722a81613687a35b070263f030f2dcc1d Mon Sep 17 00:00:00 2001 From: Michal Klos Date: Mon, 30 Mar 2026 13:50:45 +0200 Subject: [PATCH] feat: [OCISDEV-744] cli-test --- .github/workflows/acceptance-tests.yml | 51 ++++++++++++++++++++++++-- tests/acceptance/run-github.py | 4 +- 2 files changed, 51 insertions(+), 4 deletions(-) diff --git a/.github/workflows/acceptance-tests.yml b/.github/workflows/acceptance-tests.yml index 22e3a9f1d13..f5512b8835e 100644 --- a/.github/workflows/acceptance-tests.yml +++ b/.github/workflows/acceptance-tests.yml @@ -113,12 +113,18 @@ jobs: # - apiCollaboration steps: - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - - uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6.3.0 with: go-version-file: go.mod cache: true - + + - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 + with: + node-version: "24" + + - name: Enable pnpm + run: corepack enable && corepack prepare pnpm@10.28.1 --activate + - name: Install libcurl 8.12.0 from source run: | sudo apt-get update -qq @@ -150,6 +156,38 @@ jobs: - name: Run ${{ matrix.suite }} run: BEHAT_SUITES=${{ matrix.suite }} python3 tests/acceptance/run-github.py + cli-tests: + needs: [build-and-test] + name: ${{ matrix.suite }} + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + suite: + - cliCommands,apiServiceAvailability # grouped like drone; needs ClamAV + email + steps: + - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 + - uses: actions/setup-go@4b73464bb391d4059bd26b0524d20df3927bd417 # v6.3.0 + with: + go-version-file: go.mod + cache: true + + - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 + with: + node-version: "24" + + - name: Enable pnpm + run: corepack enable && corepack prepare pnpm@10.28.1 --activate + + - uses: shivammathur/setup-php@accd6127cb78bee3e8082180cb391013d204ef9f # 2.37.0 + with: + php-version: "8.4" + extensions: curl, xml, mbstring, zip + tools: composer + + - name: Run ${{ matrix.suite }} + run: BEHAT_SUITES="${{ matrix.suite }}" python3 tests/acceptance/run-github.py + core-api-tests: name: ${{ matrix.suite }} needs: [build-and-test] @@ -169,6 +207,13 @@ jobs: go-version-file: go.mod cache: true + - uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0 + with: + node-version: "24" + + - name: Enable pnpm + run: corepack enable && corepack prepare pnpm@10.28.1 --activate + - name: Install libcurl 8.12.0 from source run: | sudo apt-get update -qq @@ -212,7 +257,7 @@ jobs: path: tests/acceptance/output/ all-acceptance-tests: - needs: [local-api-tests, core-api-tests] + needs: [local-api-tests, cli-tests, core-api-tests] runs-on: ubuntu-latest if: always() steps: diff --git a/tests/acceptance/run-github.py b/tests/acceptance/run-github.py index 6e6bf51295f..a1c34fd4d9d 100755 --- a/tests/acceptance/run-github.py +++ b/tests/acceptance/run-github.py @@ -193,7 +193,6 @@ def base_server_env(repo_root: Path, ocis_url: str, ocis_config_dir: str) -> dic "OCIS_CONFIG_DIR": ocis_config_dir, "STORAGE_USERS_DRIVER": "ocis", "PROXY_ENABLE_BASIC_AUTH": "true", - "OCIS_EXCLUDE_RUN_SERVICES": "idp", "OCIS_LOG_LEVEL": "error", "IDM_CREATE_DEMO_USERS": "true", "IDM_ADMIN_PASSWORD": "admin", @@ -320,6 +319,9 @@ def main() -> int: f"antivirus={cfg['antivirusNeeded']} federation={cfg['federationServer']} " f"wopi={cfg['collaborationServiceNeeded']}") + # generate IDP web assets (required for IDP service to start; matches drone ci-node-generate) + run(["make", "-C", str(repo_root / "services/idp"), "ci-node-generate"]) + # build (ENABLE_VIPS=true when libvips-dev is installed, matching drone) build_env = {} if subprocess.run(["pkg-config", "--exists", "vips"],