From f2ba1bd4ab59ed22cf3d7a29df4dcddc993113e1 Mon Sep 17 00:00:00 2001 From: Luka Trovic Date: Tue, 26 Apr 2022 10:44:53 +0200 Subject: [PATCH] fix: make cypress tests pass Signed-off-by: Luka Trovic --- .github/workflows/cypress.yml | 12 +++++++----- cypress.json | 2 +- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/cypress.yml b/.github/workflows/cypress.yml index 4fc50977c..b0bc97882 100644 --- a/.github/workflows/cypress.yml +++ b/.github/workflows/cypress.yml @@ -9,7 +9,7 @@ on: env: APP_NAME: deck - CYPRESS_baseUrl: http://nextcloud.local/index.php/ + CYPRESS_baseUrl: http://nextcloud.local/index.php jobs: cypress: @@ -26,8 +26,10 @@ jobs: server-versions: [ 'master' ] steps: - - name: Setup custom host for nextcloud - run: echo "localhost nextcloud.local" | sudo tee -a /etc/hosts + - name: Set up custom host for nextcloud + run: | + sudo echo "127.0.0.1 nextcloud.local" | sudo tee -a /etc/hosts + cat /etc/hosts - name: Use Node.js ${{ matrix.node-version }} uses: actions/setup-node@v1 @@ -73,13 +75,13 @@ jobs: php occ config:system:set memcache.local --value="\\OC\\Memcache\\APCu" php occ config:system:set debug --value=true --type=boolean php -f index.php - php -S 0.0.0.0:80 & + sudo php -S 0.0.0.0:80 & export OC_PASS=1234561 php occ user:add --password-from-env user1 php occ user:add --password-from-env user2 php occ app:enable deck php occ app:list - curl -v http://localhost/index.php/login + curl -v http://nextcloud.local/index.php/login cat data/nextcloud.log - name: Cypress run diff --git a/cypress.json b/cypress.json index 895dff52e..6f535d60f 100644 --- a/cypress.json +++ b/cypress.json @@ -1,5 +1,5 @@ { - "baseUrl": "http://nextcloud.local/index.php/", + "baseUrl": "http://nextcloud.local/index.php", "projectId": "hx9gqy", "viewportWidth": 1280, "viewportHeight": 720,