Local testing branch#10
Merged
Merged
Conversation
The close modal is also used in 'forms' for closing settings, which broke the 'new file modal' test for forms.
Comment on lines
+10
to
+123
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Clone CryptPad repository | ||
| env: | ||
| PA_TOKEN: ${{ secrets.PAT_SECRET }} | ||
| run: git clone "https://"$PA_TOKEN"@github.com/cryptpad/cryptpad.git" -b database_seed_rc2025.3 | ||
| shell: bash | ||
| - name: Seed database | ||
| working-directory: cryptpad | ||
| run: unzip -o database_seed.zip | ||
| if: always() | ||
| # - name: Clone CryptPad repository | ||
| # env: | ||
| # PA_TOKEN: ${{ secrets.PAT_SECRET }} | ||
| # run: git clone "https://"$PA_TOKEN"@github.com/cryptpad/cryptpad.git" | ||
| # shell: bash | ||
| - name: Checkout branch | ||
| working-directory: cryptpad | ||
| run: | | ||
| git checkout 2025.3.1-rc | ||
| git branch | ||
| - name: Install dependencies | ||
| run: npm install --prefix cryptpad | ||
| - name: Install components 1 | ||
| run: npm ci --prefix cryptpad | ||
| - name: Install components 2 | ||
| run: npm run install:components --prefix cryptpad | ||
| - name: Install OnlyOffice | ||
| run: cryptpad/install-onlyoffice.sh -a | ||
| if: always() | ||
| - name: Run local server | ||
| timeout-minutes: 180 | ||
| run: nohup npm run dev --prefix cryptpad & | ||
| - name: Clone test repository | ||
| env: | ||
| PA_TOKEN: ${{ secrets.PAT_SECRET }} | ||
| run: git clone "https://"$PA_TOKEN"@github.com/cryptpad/e2e-test-suite.git" -b local_testing_branch | ||
| shell: bash | ||
| - name: Install dependencies | ||
| run: npm ci --prefix e2e-test-suite | ||
| - name: Install dependencies 2 | ||
| run: npm exec playwright install --with-deps --prefix e2e-test-suite | ||
| - name: Install dependencies 3 | ||
| run: npm exec playwright install-deps --prefix e2e-test-suite | ||
| - name: Install test reporter | ||
| run: npm install playwright-ctrf-json-reporter --prefix e2e-test-suite | ||
| - name: Calibrate Playwright screenshot tests (anon) | ||
| working-directory: e2e-test-suite | ||
| run: npx playwright test -g "screenshot anon" --config=playwright.config.js --project='chrome' --workers=2 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| if: always() | ||
| - name: Run Playwright tests (anon) | ||
| working-directory: e2e-test-suite | ||
| run: npx playwright test anon --config=playwright.config.js --project='chrome' --workers=2 --retries=1 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| if: always() | ||
| - name: Publish Test Report (anon) | ||
| uses: ctrf-io/github-test-reporter@v1 | ||
| with: | ||
| report-path: 'e2e-test-suite/ctrf/*.json' | ||
| title: 'Test results - anonymous' | ||
| if: always() | ||
| - name: Seed database | ||
| working-directory: e2e-test-suite | ||
| run: | | ||
| npx playwright test dbseeding --config=playwright.config.js --project='chrome' --workers=1 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| MAINACCOUNTPASSWORD: ${{ vars.MAINACCOUNTPASSWORD }} | ||
| TESTUSERPASSWORD: ${{ vars.TESTUSERPASSWORD }} | ||
| TESTUSER2PASSWORD: ${{ vars.TESTUSER2PASSWORD }} | ||
| TESTUSER3PASSWORD: ${{ vars.TESTUSER3PASSWORD }} | ||
| - name: Create auth files | ||
| working-directory: e2e-test-suite | ||
| run: | | ||
| mkdir auth | ||
| cd auth | ||
| touch mainuser.json testuser.json testuser2.json testuser3.json | ||
| if: always() | ||
| - name: Authenticate users | ||
| working-directory: e2e-test-suite | ||
| run: | | ||
| npx playwright test auth --config=playwright.config.js --project='chrome' --workers=1 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| MAINACCOUNTPASSWORD: ${{ vars.MAINACCOUNTPASSWORD }} | ||
| TESTUSERPASSWORD: ${{ vars.TESTUSERPASSWORD }} | ||
| TESTUSER2PASSWORD: ${{ vars.TESTUSER2PASSWORD }} | ||
| TESTUSER3PASSWORD: ${{ vars.TESTUSER3PASSWORD }} | ||
| if: always() | ||
| - name: Calibrate Playwright screenshot tests (logged in users) | ||
| working-directory: e2e-test-suite | ||
| run: npx playwright test -g "screenshot loggedin" --config=playwright.config.js --project='chrome' --workers=2 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| if: always() | ||
| - name: Run Playwright tests (logged in users) | ||
| working-directory: e2e-test-suite | ||
| run: npx playwright test loggedin --config=playwright.config.js --project='chrome' --workers=1 --retries=2 | ||
| env: | ||
| PW_URL: ${{ vars.PW_URL }} | ||
| MAINACCOUNTPASSWORD: ${{ vars.MAINACCOUNTPASSWORD }} | ||
| TESTUSERPASSWORD: ${{ vars.TESTUSERPASSWORD }} | ||
| TESTUSER2PASSWORD: ${{ vars.TESTUSER2PASSWORD }} | ||
| TESTUSER3PASSWORD: ${{ vars.TESTUSER3PASSWORD }} | ||
| if: always() | ||
| - name: Publish Test Report (logged in users) | ||
| uses: ctrf-io/github-test-reporter@v1 | ||
| with: | ||
| report-path: 'e2e-test-suite/ctrf/*.json' | ||
| title: 'Test results - logged in users' | ||
| if: always() |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.