* Use cypress-terminal-report
This cypress plugin gives nice console logs about what is happening: I hope it
will help us debug mysteriously failing tests.
In its default config, it only logs for failing tests.
* another anti-morgan hack
* Disable collection of `console.debug`
* `ctr:info` is not real
* Remove STIXGeneral from the font stack
STIXGeneral was originally added to our font stack to work around a bug in Chrome (https://bugs.chromium.org/p/chromium/issues/detail?id=591346) which caused some obscure combining marks to render as tofu. However, because STIXGeneral unexpectedly has glyphs for a handful of common Japanese characters, it's ended up making Japanese text in Element look patchy. I previously attempted to fix this by prioritizing sans-serif over STIXGeneral, but as is evident from our screenshot tests and user reports, this is still not enough on some systems to get Chrome to pick a consistent font for Japanese. On the basis that i18n is more important than supporting a few mathematical diacritics, I propose we remove the font. STIXGeneral is deprecated anyways, so if we want to get these diacritics back there's always the option of looking at its successor, STIXTwo.
* Remove STIXGeneral installation from Cypress workflow
* GHA: make `element-web` workflow reusable
... so that we can call it from the js-sdk repo
* GHA: make `cypress.yaml` a reusable workflow
... so that we can call it from js-sdk
* GHA: give cypress.yaml a `rust-crypto` parameter
* Update .github/workflows/cypress.yaml
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* remove workflow_dispatch
---------
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
Context: `fetchdep.sh` attempts to check out a github repository based on the
details in a pull request. To do this, it needs to know how to find the pull
request. So, the github workflows attempt to set environment variables to tell
it. Unfortunately, they currently disagree about what the names of the
environment variables should be.
This appears to have been introduced by #8498.
To simplify matters, we may as well have the script use `${GITHUB_REPOSITORY}`
directly, and remove te unused `REPOSITORY` env var from the workflows.
We are not interested in coverage information when a PR has already been
approved, and we were seeing flakiness with SonarCloud with the "no
artifacts found" error
https://github.com/vector-im/element-web/issues/25334 .
* Cypress use the simulated merge commit for the source of tests
* Add comments
* Update .github/workflows/cypress.yaml
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
---------
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
Change from string-y checking for true ('0' is true) to comparison against the string '1', which is only true if exactly equal to '1'.
This has been submitting more test results to Kiwi than we want/need.
* Stop running Percy on develop builds
Instead, we will run it daily. This will reduce the number of Percy
tests we run each month.
* Run screenshot tests daily
* Prettier for percy_daily.yml
* Maybe something like this
* Update all non-major dependencies
* downgrade axe due to test failures
* ci: force rerun
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Janne Mareike Koschinski <jannemk@element.io>
* Don't prefer STIXGeneral over the default font
STIXGeneral contains some glyphs for non-LGC scripts, but often doesn't implement these scripts fully. We should always try the browser's default fonts, which are likely to look nicer and have broader script support, before falling back to STIXGeneral.
* Explain why STIXGeneral shouldn't have precedence
* Add a regression test
* Reduce cypress size/scope
* Emit cypress reports in junit-compatible format.
* Clean implementation of upload
* Append a warning if not all tests that testrail knows of are run.
* Only run testrail if on develop (like percy).
* Re-enable full test run.
* Update cypress.config.ts
* Ensure SUITE_ID is passed.
* Fix quoting on SUITE_ID, add environment
* Update .github/workflows/cypress.yaml
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* re-add mocha-junit-reporter (was dropped in the merge)
* Prettifier on newly created file.
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
* Typescript updates
* Update @types/node
* Fix more types
* Update all non-major dependencies
* Remove spurious cast
* Remove unused dependency rrweb-snapshot
* Update all non-major dependencies
* Iterate PR
* Update yarn.lock
* Remove stale dev dep
* Resolve
* Pin back axe-core for now, it is a bit too strict
Co-authored-by: Michael Telatynski <7t3chguy@gmail.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
* Port remaining Puppeteer tests over to Cypress
* Remove puppeteer support files
* Fix lifecycle matrixclientpeg setup race condition
* Alternative solution to the lifecycle problem
* Dismiss the notifications toast
* Add a basic PR checklist for all PRs
It'll be mildly annoying for core developers who have to constantly remove or edit this, but it'll also serve as a good reminder to do these things.
Note that signoff is not required for core developers.
* *ahem*
* Split Cypress out into its own workflow
* Improve PR Details job to use github-script and output labels
* Fix wrongly using github.ref in workflow_run actions which always refer to develop
* Update pr-details to be far more generic
* Tweak how we fill command-prefix
* Tweak cypress job to pass more params & fix if condition
* Bring in external changes
* Add docs
* Use new composite action, and an action to update a status check based on this workflow run
* Iterate approach
* Switch to composite actions for pr_details and sonarqube
* Bring back a reusable workflow for element-web stack sonarqube runs
* Move sonarcloud.yml to the right repo
* Fix Netlify run
* Move spaces tests from Puppeteer to Cypress
* Add missing fixture
* Tweak synapsedocker to not double error on a docker failure
* Fix space hierarchy loading race condition
Fixes https://github.com/matrix-org/element-web-rageshakes/issues/10345
* Fix race condition when creating public space with url update code
* Try Electron once more due to perms issues around clipboard
* Try set browser permissions properly
* Try to enable clipboard another way
* Try electron again
* Try electron again again
* Switch to built-in cypress feature for file uploads
* Mock clipboard instead
* TMPDIR ftw?
* uid:gid pls
* Clipboard tests can now run on any browser due to mocking
* Test Enter as well as button for space creation
* Make the test actually work
* Update cypress/support/util.ts
Co-authored-by: Eric Eastwood <erice@element.io>
Co-authored-by: Eric Eastwood <erice@element.io>
* Split Cypress out into its own workflow
* Improve PR Details job to use github-script and output labels
* Fix wrongly using github.ref in workflow_run actions which always refer to develop
* Update pr-details to be far more generic
* Tweak how we fill command-prefix