|
| 1 | +name: GUI Tests |
| 2 | + |
| 3 | +on: |
| 4 | + pull_request: |
| 5 | + push: |
| 6 | + branches: [ master ] |
| 7 | + tags: [ "*" ] |
| 8 | + |
| 9 | +env: |
| 10 | + DEFAULT_PHP_VERSION: "7.4" |
| 11 | + MYSQL: "mysql:8.0" |
| 12 | + OC_CI_ALPINE: "owncloudci/alpine:latest" |
| 13 | + OC_CI_CLIENT: "owncloudci/client:latest" |
| 14 | + OC_CI_DRONE_SKIP_PIPELINE: "owncloudci/drone-skip-pipeline" |
| 15 | +# OC_CI_NODEJS: "owncloudci/nodejs:18" |
| 16 | + OC_CI_PHP: "owncloudci/php:%s" |
| 17 | + OC_CI_WAIT_FOR: "owncloudci/wait-for:latest" |
| 18 | +# OC_OCIS: "owncloud/ocis-rolling:%s" |
| 19 | + OC_UBUNTU: "owncloud/ubuntu:20.04" |
| 20 | +# OC_CI_SQUISH: "owncloudci/squish:fedora-42-8.1.0-qt68x-linux64" |
| 21 | + PLUGINS_GIT_ACTION: "plugins/git-action:1" |
| 22 | + PLUGINS_S3: "plugins/s3:1.4.0" |
| 23 | + TOOLHIPPIE_CALENS: "toolhippie/calens:0.4.0" |
| 24 | + # npm packages to install |
| 25 | + NPM_GHERLINT: "@gherlint/[email protected]" |
| 26 | + S3_PUBLIC_CACHE_SERVER: "https://cache.owncloud.com" |
| 27 | + S3_PUBLIC_CACHE_BUCKET: "public" |
| 28 | + |
| 29 | +jobs: |
| 30 | + lint-gui-test: |
| 31 | + runs-on: ubuntu-latest |
| 32 | + container: |
| 33 | + image: owncloudci/squish:fedora-42-8.1.0-qt68x-linux64 |
| 34 | + steps: |
| 35 | + - name: Checkout |
| 36 | + uses: actions/checkout@v4 |
| 37 | + |
| 38 | + - name: Setup NodeJs |
| 39 | + uses: actions/setup-node@v4 |
| 40 | + with: |
| 41 | + node-version: 18 |
| 42 | + |
| 43 | + - name: Python lint |
| 44 | + run: | |
| 45 | + make -C test/gui install |
| 46 | + make -C test/gui python-lint |
| 47 | +
|
| 48 | + - name: Gherkin lint |
| 49 | + run: | |
| 50 | + npm install -g ${{ env.NPM_GHERLINT }} |
| 51 | + make -C test/gui gherkin-lint |
| 52 | +
|
| 53 | + gui-tests: |
| 54 | + runs-on: ubuntu-latest |
| 55 | + container: |
| 56 | + image: owncloudci/squish:fedora-42-8.1.0-qt68x-linux64 |
| 57 | + services: |
| 58 | + ocis: |
| 59 | + image: owncloud/ocis-rolling:latest |
| 60 | + env: |
| 61 | + OCIS_URL: https://ocis:9200 |
| 62 | + IDM_ADMIN_PASSWORD: admin |
| 63 | + STORAGE_HOME_DRIVER: ocis |
| 64 | + STORAGE_USERS_DRIVER: ocis |
| 65 | + OCIS_INSECURE: true |
| 66 | + PROXY_ENABLE_BASIC_AUTH: true |
| 67 | + OCIS_LOG_LEVEL: error |
| 68 | + OCIS_LOG_PRETTY: true |
| 69 | + OCIS_LOG_COLOR: true |
| 70 | + ports: |
| 71 | + - 9200:9200 |
| 72 | + steps: |
| 73 | + - name: Checkout |
| 74 | + uses: actions/checkout@v4 |
| 75 | + |
| 76 | + - name: Build client |
| 77 | + run: | |
| 78 | + mkdir -p build |
| 79 | + cd build |
| 80 | + cmake -G"Ninja" -DCMAKE_BUILD_TYPE=Debug -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DBUILD_TESTING=OFF -S .. |
| 81 | + ninja |
| 82 | +
|
| 83 | + - name: Install Python Modules |
| 84 | + env: |
| 85 | + PLAYWRIGHT_BROWSERS_PATH: .playwright |
| 86 | + run: | |
| 87 | + make -C test/gui install |
| 88 | + python3.10 -m pip list -v |
| 89 | +
|
| 90 | + - name: Create GUI test report directory |
| 91 | + run: | |
| 92 | + mkdir test/gui/guiReportUpload/screenshots -p |
| 93 | + chmod 777 test/gui -R |
| 94 | +
|
| 95 | + - name: Set squish parameters |
| 96 | + run: | |
| 97 | + SQUISH_PARAMETERS="--testsuite test/gui \ |
| 98 | + --reportgen html,test/gui/guiReportUpload \ |
| 99 | + --envvar QT_LOGGING_RULES=sync.httplogger=true;gui.socketapi=false \ |
| 100 | + --tags ~@skip \ |
| 101 | + --tags ~@skipOnLinux" |
| 102 | +
|
| 103 | + - name: Run GUI test |
| 104 | + env: |
| 105 | + LICENSEKEY: ${{ secrets.SQUISH_LICENSEKEY }} |
| 106 | + GUI_TEST_REPORT_DIR: test/gui/guiReportUpload |
| 107 | + CLIENT_REPO: . |
| 108 | + BACKEND_HOST: https://ocis:9200 |
| 109 | + SECURE_BACKEND_HOST: https://ocis:9200 |
| 110 | + OCIS: true |
| 111 | + SERVER_INI: test/gui/drone/server.server.ini |
| 112 | + SQUISH_PARAMETERS: ${{ env.SQUISH_PARAMETERS }} |
| 113 | + STACKTRACE_FILE: test/gui/guiReportUpload/stacktrace.log |
| 114 | + PLAYWRIGHT_BROWSERS_PATH: .playwright |
| 115 | + OWNCLOUD_CORE_DUMP: 1 |
| 116 | + RECORD_VIDEO_ON_FAILURE: false |
| 117 | + # allow to use any available pnpm version |
| 118 | + COREPACK_ENABLE_STRICT: 0 |
| 119 | + run: | |
| 120 | + ls -la |
| 121 | + ls -la / |
| 122 | + ls -la /opt |
| 123 | + bash /dockerstartup/entrypoint.sh |
0 commit comments