-
-
Notifications
You must be signed in to change notification settings - Fork 6.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Cypress to v10 and fix E2E errors #3459
Update Cypress to v10 and fix E2E errors #3459
Conversation
Fixes xx9 test to continue running even if JavaScript throws an exception.
Widen flowchart width acceptable values to within 10% of 300px. On my local environment, I'm getting 283px, which is 5.5% of 300px.
gitGraph render tests are currently using random commit ids, which causes visual regression tests to fail. I couldn't find a way to make the random commit IDs consistent (JavaScript/Cypress doesn't seem to have a random.seed() function), so I've just hardcoded all the commit ids.
The arrows between flowcharts do not have the class edgePath. Instead, I'm loading all `<path>`s within the `<g class='edgePaths'>`
The if-check for arrowMarkerAbsolute in the flowchart-v2 code is in dagre-wrapper. Unfortunately, I can't seem to find a way to find the local conf (e.g. the one set via `flowRenderer.setConf()`, so instead I'm using global mermaid config from `src/config`. Flowchart v1 arrowMarkerAbsolute=true is still broken, but I'm not really sure how to fix that.
Cypress v10 had some minor breaking changes, (e.g. the cypress/plugins folder dissapeared) so I had to change some things. It looks like the Cypress was previously reverted in [dee9cfe][1], due to applitools not working properly, but I think my changes fix this, so it should be okay. [1]: mermaid-js@dee9cfe
Uses prettier to fix e2e style issues.
I've removed the coverage upload bit, since although the [@cypress/code-coverage][1] plugin is pretty easy to setup, it requires babel, which we're about to remove and replace with ESBuild.
This is great! Nice to finally to be able to use cypress 10 and not lagging behind. This is a really important part of our release process so it is worth getting right. We have had issues in the past where the quota has been blown away by PRs causing issues with the release flow! It is good to have it running using actions to keep it consistent and not depending on you local computer. How and when to trigger the tests
@aloisklink Maybe we can start by having it run manually and add automatic steps in iterations. A no-brainer is to have it run when we branch to a release branch. |
@@ -0,0 +1,61 @@ | |||
name: E2E | |||
|
|||
on: [push, pull_request] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aloisklink Se my comment regarding when to trigger
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've deleted the commit adding Applitools to CI, and will create a new PR that adds a e2e-applitool.yml
CI action.
The e2e.yml
test now doesn't use Applitools, so it's fine to have it run on every push/PR, since GitHub Actions is currently completely free for open-source projects.
.github/workflows/e2e.yml
Outdated
env: | ||
# e.g. mermaid-js/mermaid/my-branch | ||
APPLITOOLS_BRANCH: ${{ github.repository }}/${{ github.ref_name }} | ||
APPLITOOLS_PARENT_BRANCH: develop |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I read this is at it creates a branch name from the github branch in question and compares this will the develop baseline?
This is good for all develop related comparisons but in the release flow we want to compare with last release baseline. This gives an extra layer of security as it is possible to falsly approve a snapshot in develop.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've removed the Applitools CI action from this PR, and will fix this in another PR once I figure out the best way to manually trigger workflows.
if (!cnf.flowchart) { | ||
cnf.flowchart = {}; | ||
} | ||
// TODO, broken as of 2022-09-14 (13809b50251845475e6dca65cc395761be38fbd2) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Will fix in another PR
Hi @knsv, it looks like getting Applitools running on GitHub Actions will be a bit difficult. How about I delete commit dbbe95c in this PR? Instead, this PR's Then I'll make another PR that adds
This might be difficult for external PRs. The
👍 Sounds good to me :) |
Do you think we can keep the screenshots in the repo and run local verification instead of relying on applitools for PRs?
|
Two issues I see with this:
|
dbbe95c
to
20d22a6
Compare
I've removed commit dbbe95c which added Applitools to GitHub Actions CI. This PR still adds e2e rendering tests, even if it doesn't have visual regression tests. I'll make another PR that adds Applitools E2E tests on CI, since that will get a bit of working out to setup. |
@knsv Not related to cypress, but shouldn't we change to a properly "open" font? Another option is to run tests twice.
It'll take some CI time, but will make the lives of the maintainers easier. |
It's not too big of a deal, since browsers will just fallback to other similar fonts. If we do switch, we may want to use a webfont (I like Atkinson Hyperlegible, since it's designed for people with low vision), since then everybody's browser will download the same font. But then again, webfonts have issues with download speeds, offline browsers, and privacy concerns (if we use a CDN).
I can't believe I didn't think of that! That's work pretty well. It will probably get a bit more complicated, since we'd also need a way to view the image differences, but I think that should just be uploading a |
We can store that as artifacts with a lifetime of 3-5days. |
You guys have been active in this discussion 👍 About the font, there is nothing special with Trebuchet other then that it is a web-safe font. Lets keep until there is an issue with it. In the cypress tests there should be a wider font. We had issues for a while in the beginning, with cut text in the boxes resulting from the boxes being sized with a more narrow font than the one used in the final presentation. It is good to have that as a part of the automatic tests as worst case scenarios. I understand that by merging this we have the appli tools run manually for now. ✅ The problem with having baseline images compared between different environments are very real. Slight changes in antialiasing between for instance linux and mac causes issues. So the method of running the tests twice would work better than the other options. So I am in favour of that. We should document and strongly promote to use a similar process to the PR authors.
|
So merge now and add the other stuff in next PR? |
Sounds good to me 👍 Since we're not adding the Applitools stuff in this PR, I think it's relatively low risk to merge now. In the worst case scenario, we can always do a |
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [mermaid](https://togithub.com/mermaid-js/mermaid) | [`9.1.7` -> `9.2.2`](https://renovatebot.com/diffs/npm/mermaid/9.1.7/9.2.2) | [![age](https://badges.renovateapi.com/packages/npm/mermaid/9.2.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/npm/mermaid/9.2.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/npm/mermaid/9.2.2/compatibility-slim/9.1.7)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/npm/mermaid/9.2.2/confidence-slim/9.1.7)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>mermaid-js/mermaid</summary> ### [`v9.2.2`](https://togithub.com/mermaid-js/mermaid/releases/tag/v9.2.2): 9.2.2 [Compare Source](https://togithub.com/mermaid-js/mermaid/compare/v9.2.1...v9.2.2) #### What's Changed - \[9.2] fix(mermaid): fix `mermaid.render` types by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3768](https://togithub.com/mermaid-js/mermaid/pull/3768) - \[9.2] fix(mermaid): default mermaid back to CommonJS by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3767](https://togithub.com/mermaid-js/mermaid/pull/3767) - Fix lazy loading in webpack by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3774](https://togithub.com/mermaid-js/mermaid/pull/3774) **Full Changelog**: mermaid-js/mermaid@v9.2.1...v9.2.2 ### [`v9.2.1`](https://togithub.com/mermaid-js/mermaid/releases/tag/v9.2.1): 9.2.1 [Compare Source](https://togithub.com/mermaid-js/mermaid/compare/v9.2.0...v9.2.1) #### What's Changed - \~~fix [#​3757](https://togithub.com/mermaid-js/mermaid/issues/3757) : Remove dynamic imports for lazy load causing issues for webpack~~ - chore: Update bug report template by [@​gibson042](https://togithub.com/gibson042) in [https://github.com/mermaid-js/mermaid/pull/3727](https://togithub.com/mermaid-js/mermaid/pull/3727) - Use issue templates and add diagram, theme and syntax proposal issue forms by [@​Andre601](https://togithub.com/Andre601) in [https://github.com/mermaid-js/mermaid/pull/2739](https://togithub.com/mermaid-js/mermaid/pull/2739) #### New Contributors - [@​Andre601](https://togithub.com/Andre601) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/2739](https://togithub.com/mermaid-js/mermaid/pull/2739) **Full Changelog**: mermaid-js/mermaid@v9.2.0...v9.2.1 ### [`v9.2.0`](https://togithub.com/mermaid-js/mermaid/releases/tag/v9.2.0): 9.2.0 [Compare Source](https://togithub.com/mermaid-js/mermaid/compare/v9.1.7...v9.2.0) #### What's Changed ##### Features - Mindmaps by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3410](https://togithub.com/mermaid-js/mermaid/pull/3410) - Introducing TypeScript by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3336](https://togithub.com/mermaid-js/mermaid/pull/3336) - Auto transform `mermaid-example` in docs. by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3401](https://togithub.com/mermaid-js/mermaid/pull/3401) - Creating detectors and moving out diagram specific code from the diag… by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3436](https://togithub.com/mermaid-js/mermaid/pull/3436) - feat(git): cherry-pick keyword supports tag attribute by [@​elliot-nelson](https://togithub.com/elliot-nelson) in [https://github.com/mermaid-js/mermaid/pull/3479](https://togithub.com/mermaid-js/mermaid/pull/3479) - Mindmaps replacing rendering algoritm with cose-bilkent by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3559](https://togithub.com/mermaid-js/mermaid/pull/3559) - 3561 theme color scales by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3562](https://togithub.com/mermaid-js/mermaid/pull/3562) - ESBuild by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3386](https://togithub.com/mermaid-js/mermaid/pull/3386) - (Beta) Lazy load import by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3592](https://togithub.com/mermaid-js/mermaid/pull/3592), [https://github.com/mermaid-js/mermaid/pull/3598](https://togithub.com/mermaid-js/mermaid/pull/3598) - 3061 making a monorepo by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3531](https://togithub.com/mermaid-js/mermaid/pull/3531) ##### Fixes - Feature decimal duration in second for gantt diagram by [@​vallsv](https://togithub.com/vallsv) in [https://github.com/mermaid-js/mermaid/pull/3360](https://togithub.com/mermaid-js/mermaid/pull/3360) - fix: fix passing a single Node to mermaid.init() by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3396](https://togithub.com/mermaid-js/mermaid/pull/3396) - fix [#​3407](https://togithub.com/mermaid-js/mermaid/issues/3407) Replace `div` with `pre` and format by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3408](https://togithub.com/mermaid-js/mermaid/pull/3408) - fix(git): support numeric branch names by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3392](https://togithub.com/mermaid-js/mermaid/pull/3392) - Add tests for C4 system context macros by [@​dbartholomae](https://togithub.com/dbartholomae) in [https://github.com/mermaid-js/mermaid/pull/3367](https://togithub.com/mermaid-js/mermaid/pull/3367) - Add nested test for parseGenericTypes by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3354](https://togithub.com/mermaid-js/mermaid/pull/3354) - Fix memoize by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3434](https://togithub.com/mermaid-js/mermaid/pull/3434) - fix(git): support single character branch names by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3464](https://togithub.com/mermaid-js/mermaid/pull/3464) - Replace GoogleAnalytics with Plausible by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3466](https://togithub.com/mermaid-js/mermaid/pull/3466) - Fix for issues in errorhandling and class diagrams after refactoring by [@​knsv](https://togithub.com/knsv) in [https://github.com/mermaid-js/mermaid/pull/3470](https://togithub.com/mermaid-js/mermaid/pull/3470) - 3409 Fix for truncated tags in GitGraph by [@​ashishjain0512](https://togithub.com/ashishjain0512) in [https://github.com/mermaid-js/mermaid/pull/3454](https://togithub.com/mermaid-js/mermaid/pull/3454) - Fix broken cherry-pick parsing in gitgraph by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3480](https://togithub.com/mermaid-js/mermaid/pull/3480) - Fix CI `docs:lint` by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3493](https://togithub.com/mermaid-js/mermaid/pull/3493) - Fix user-journey leaking css by [@​lishid](https://togithub.com/lishid) in [https://github.com/mermaid-js/mermaid/pull/3510](https://togithub.com/mermaid-js/mermaid/pull/3510) - \[sequenceDiagrams] Support dashes in participant names by [@​ashleybartlett](https://togithub.com/ashleybartlett) in [https://github.com/mermaid-js/mermaid/pull/3524](https://togithub.com/mermaid-js/mermaid/pull/3524) - fix: ER dark theme attribute colors by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3512](https://togithub.com/mermaid-js/mermaid/pull/3512) - feat: ER diagram: allow other chars in a quoted entity name by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3516](https://togithub.com/mermaid-js/mermaid/pull/3516) - Arrow tip aligned to edge of box by [@​pbrolin47](https://togithub.com/pbrolin47) in [https://github.com/mermaid-js/mermaid/pull/3533](https://togithub.com/mermaid-js/mermaid/pull/3533) - Fixed labelText undefined behavior by [@​AndrewL-64](https://togithub.com/AndrewL-64) in [https://github.com/mermaid-js/mermaid/pull/3544](https://togithub.com/mermaid-js/mermaid/pull/3544) - Fix failing vitest unit tests by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3587](https://togithub.com/mermaid-js/mermaid/pull/3587) - fix: Import diagram by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3589](https://togithub.com/mermaid-js/mermaid/pull/3589) - Fix file name during "pnpm run dev" script by [@​vallsv](https://togithub.com/vallsv) in [https://github.com/mermaid-js/mermaid/pull/3608](https://togithub.com/mermaid-js/mermaid/pull/3608) - fix Detect diagram fallback by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3591](https://togithub.com/mermaid-js/mermaid/pull/3591) - fix: Dirty fix for sync render. by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3633](https://togithub.com/mermaid-js/mermaid/pull/3633) - fix: Converts mindmapDB to TS by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3683](https://togithub.com/mermaid-js/mermaid/pull/3683) - Support `lazyLoadedDiagrams` when calling `initThrowsErrors` by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3702](https://togithub.com/mermaid-js/mermaid/pull/3702) - \[9.2.0] Support `lazyLoadedDiagrams` when calling `initThrowsErrorsAsync` by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3731](https://togithub.com/mermaid-js/mermaid/pull/3731) ##### Chores - build: run `build:prod` on `yarn prepare` by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3404](https://togithub.com/mermaid-js/mermaid/pull/3404) - chore(deps-dev): bump [@​types/dompurify](https://togithub.com/types/dompurify) from 2.3.3 to 2.3.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3414](https://togithub.com/mermaid-js/mermaid/pull/3414) - chore(deps-dev): bump jest-environment-jsdom from 29.0.1 to 29.0.2 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3413](https://togithub.com/mermaid-js/mermaid/pull/3413) - chore(deps-dev): bump typescript from 4.7.4 to 4.8.2 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3411](https://togithub.com/mermaid-js/mermaid/pull/3411) - chore(deps-dev): bump babel-jest from 29.0.1 to 29.0.2 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3412](https://togithub.com/mermaid-js/mermaid/pull/3412) - chore: fix JSDOC [@​param](https://togithub.com/param), [@​returns](https://togithub.com/returns) lint errors by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3422](https://togithub.com/mermaid-js/mermaid/pull/3422) - style: forbid using `console` in mermaid src code by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3405](https://togithub.com/mermaid-js/mermaid/pull/3405) - Introduce stricter typescript linting by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3393](https://togithub.com/mermaid-js/mermaid/pull/3393) - Esbuild: backwards-compatible `mermaid.core.mjs` by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3437](https://togithub.com/mermaid-js/mermaid/pull/3437) - fix(git): support unusual prefixes in branch name by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3438](https://togithub.com/mermaid-js/mermaid/pull/3438) - Re-enable coverage upload to coveralls by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3431](https://togithub.com/mermaid-js/mermaid/pull/3431) - chore(deps): bump actions/checkout from 2 to 3 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3449](https://togithub.com/mermaid-js/mermaid/pull/3449) - chore(deps-dev): bump typescript from 4.8.2 to 4.8.3 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3446](https://togithub.com/mermaid-js/mermaid/pull/3446) - chore(deps-dev): bump eslint from 8.23.0 to 8.23.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3440](https://togithub.com/mermaid-js/mermaid/pull/3440) - chore(deps-dev): bump babel-jest from 29.0.2 to 29.0.3 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3448](https://togithub.com/mermaid-js/mermaid/pull/3448) - chore(deps-dev): bump jest-environment-jsdom from 29.0.2 to 29.0.3 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3441](https://togithub.com/mermaid-js/mermaid/pull/3441) - chore(deps-dev): bump [@​babel/core](https://togithub.com/babel/core) from 7.18.13 to 7.19.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3447](https://togithub.com/mermaid-js/mermaid/pull/3447) - chore(deps-dev): bump [@​typescript-eslint/parser](https://togithub.com/typescript-eslint/parser) from 5.36.1 to 5.37.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3451](https://togithub.com/mermaid-js/mermaid/pull/3451) - chore(deps-dev): bump [@​babel/preset-env](https://togithub.com/babel/preset-env) from 7.18.10 to 7.19.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3442](https://togithub.com/mermaid-js/mermaid/pull/3442) - chore(deps-dev): bump concurrently from 7.3.0 to 7.4.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3445](https://togithub.com/mermaid-js/mermaid/pull/3445) - chore(deps-dev): bump [@​typescript-eslint/eslint-plugin](https://togithub.com/typescript-eslint/eslint-plugin) from 5.36.1 to 5.37.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3457](https://togithub.com/mermaid-js/mermaid/pull/3457) - chore(deps-dev): bump eslint-plugin-jest from 27.0.1 to 27.0.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3458](https://togithub.com/mermaid-js/mermaid/pull/3458) - Cleanup & fix eslint warnings by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3453](https://togithub.com/mermaid-js/mermaid/pull/3453) - chore(deps-dev): bump webpack-dev-server from 4.10.1 to 4.11.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3450](https://togithub.com/mermaid-js/mermaid/pull/3450) - chore(deps): bump stylis from 4.1.1 to 4.1.2 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3439](https://togithub.com/mermaid-js/mermaid/pull/3439) - chore(deps): bump dompurify from 2.3.10 to 2.4.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3444](https://togithub.com/mermaid-js/mermaid/pull/3444) - chore(deps-dev): bump [@​types/lodash](https://togithub.com/types/lodash) from 4.14.184 to 4.14.185 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3489](https://togithub.com/mermaid-js/mermaid/pull/3489) - chore(deps-dev): bump esbuild from 0.15.6 to 0.15.8 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3490](https://togithub.com/mermaid-js/mermaid/pull/3490) - chore(deps-dev): bump eslint from 8.23.1 to 8.24.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3521](https://togithub.com/mermaid-js/mermaid/pull/3521) - chore(deps-dev): bump [@​types/prettier](https://togithub.com/types/prettier) from 2.7.0 to 2.7.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3520](https://togithub.com/mermaid-js/mermaid/pull/3520) - chore: fix demo chart pages by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3523](https://togithub.com/mermaid-js/mermaid/pull/3523) - Vitest by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3427](https://togithub.com/mermaid-js/mermaid/pull/3427) - Build mermaid using Vite by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3503](https://togithub.com/mermaid-js/mermaid/pull/3503) - Add "Debug Current Test File" configuration for VSCode by [@​pje](https://togithub.com/pje) in [https://github.com/mermaid-js/mermaid/pull/3509](https://togithub.com/mermaid-js/mermaid/pull/3509) - \[DevOps] Parallel E2E by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3498](https://togithub.com/mermaid-js/mermaid/pull/3498) - chore(deps-dev): update lint-staged requirement from ^13.0.0 to ^13.0.3 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3551](https://togithub.com/mermaid-js/mermaid/pull/3551) - chore(deps-dev): update start-server-and-test requirement from ^1.12.6 to ^1.14.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3553](https://togithub.com/mermaid-js/mermaid/pull/3553) - chore(deps-dev): update jsdom requirement from ^20.0.0 to ^20.0.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3552](https://togithub.com/mermaid-js/mermaid/pull/3552) - chore(deps-dev): update [@​types/express](https://togithub.com/types/express) requirement from ^4.17.13 to ^4.17.14 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3555](https://togithub.com/mermaid-js/mermaid/pull/3555) - chore(deps-dev): update [@​types/lodash](https://togithub.com/types/lodash) requirement from ^4.14.185 to ^4.14.186 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3556](https://togithub.com/mermaid-js/mermaid/pull/3556) - chore(deps-dev): update vitest requirement from ^0.23.1 to ^0.23.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3557](https://togithub.com/mermaid-js/mermaid/pull/3557) - chore(deps-dev): update husky requirement from ^8.0.0 to ^8.0.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3558](https://togithub.com/mermaid-js/mermaid/pull/3558) - chore(deps-dev): update [@​typescript-eslint/parser](https://togithub.com/typescript-eslint/parser) requirement from ^5.37.0 to ^5.39.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3564](https://togithub.com/mermaid-js/mermaid/pull/3564) - chore(deps-dev): update [@​typescript-eslint/eslint-plugin](https://togithub.com/typescript-eslint/eslint-plugin) requirement from ^5.37.0 to ^5.39.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3565](https://togithub.com/mermaid-js/mermaid/pull/3565) - chore(deps): update [@​types/node](https://togithub.com/types/node) requirement from ^18.7.21 to ^18.8.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3566](https://togithub.com/mermaid-js/mermaid/pull/3566) - chore(deps-dev): update [@​vitest/coverage-c8](https://togithub.com/vitest/coverage-c8) requirement from ^0.23.2 to ^0.23.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3567](https://togithub.com/mermaid-js/mermaid/pull/3567) - chore(deps-dev): update esbuild requirement from ^0.15.8 to ^0.15.10 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3569](https://togithub.com/mermaid-js/mermaid/pull/3569) - chore(deps-dev): update typescript requirement from ^4.8.3 to ^4.8.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3573](https://togithub.com/mermaid-js/mermaid/pull/3573) - chore(deps-dev): update [@​applitools/eyes-cypress](https://togithub.com/applitools/eyes-cypress) requirement from ^3.25.7 to ^3.27.1 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3568](https://togithub.com/mermaid-js/mermaid/pull/3568) - chore(deps-dev): update vite requirement from ^3.0.9 to ^3.1.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3570](https://togithub.com/mermaid-js/mermaid/pull/3570) - chore(deps-dev): update eslint-plugin-jest requirement from ^27.0.4 to ^27.1.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3571](https://togithub.com/mermaid-js/mermaid/pull/3571) - chore(deps-dev): update [@​commitlint/config-conventional](https://togithub.com/commitlint/config-conventional) requirement from ^17.0.0 to ^17.1.0 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3572](https://togithub.com/mermaid-js/mermaid/pull/3572) - Fix `docs:build` and `docs:verify` scripts by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3534](https://togithub.com/mermaid-js/mermaid/pull/3534) - Fix husky `pre-commit` rules by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3536](https://togithub.com/mermaid-js/mermaid/pull/3536) - Fix typos in README.md by [@​elv-nate](https://togithub.com/elv-nate) in [https://github.com/mermaid-js/mermaid/pull/3538](https://togithub.com/mermaid-js/mermaid/pull/3538) - fix(tests): E2E by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3574](https://togithub.com/mermaid-js/mermaid/pull/3574) - fix: pnpm clean in windows by [@​arpansaha13](https://togithub.com/arpansaha13) in [https://github.com/mermaid-js/mermaid/pull/3595](https://togithub.com/mermaid-js/mermaid/pull/3595) - Update Cypress to v10 and fix E2E errors by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3459](https://togithub.com/mermaid-js/mermaid/pull/3459) - ci(e2e-applitols): add applitools CI action by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3483](https://togithub.com/mermaid-js/mermaid/pull/3483) - Remove webpack & babel by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3452](https://togithub.com/mermaid-js/mermaid/pull/3452) - Add vitepress plugin by [@​emersonbottero](https://togithub.com/emersonbottero) in [https://github.com/mermaid-js/mermaid/pull/3476](https://togithub.com/mermaid-js/mermaid/pull/3476) - ci(e2e): fix e2e action when running from fork by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3519](https://togithub.com/mermaid-js/mermaid/pull/3519) - chore(deps-dev): update [@​vitest/ui](https://togithub.com/vitest/ui) requirement from ^0.23.2 to ^0.23.4 by [@​dependabot](https://togithub.com/dependabot) in [https://github.com/mermaid-js/mermaid/pull/3549](https://togithub.com/mermaid-js/mermaid/pull/3549) - chore: Update demo diagrams for monorepo by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3545](https://togithub.com/mermaid-js/mermaid/pull/3545) - Sync `docs/` with `packages/mermaid/src/docs` by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3586](https://togithub.com/mermaid-js/mermaid/pull/3586) - chore: Add volta by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3628](https://togithub.com/mermaid-js/mermaid/pull/3628) - chore: Node 18 by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3630](https://togithub.com/mermaid-js/mermaid/pull/3630) - Configure Renovate by [@​renovate](https://togithub.com/renovate) in [https://github.com/mermaid-js/mermaid/pull/3627](https://togithub.com/mermaid-js/mermaid/pull/3627) ##### Docs - Added mermerd to integrations documentation by [@​KarnerTh](https://togithub.com/KarnerTh) in [https://github.com/mermaid-js/mermaid/pull/3399](https://togithub.com/mermaid-js/mermaid/pull/3399) - Fix typo in documentation by [@​dbartholomae](https://togithub.com/dbartholomae) in [https://github.com/mermaid-js/mermaid/pull/3403](https://togithub.com/mermaid-js/mermaid/pull/3403) - Update duplicate copy pasted directive description by [@​mrmanc](https://togithub.com/mrmanc) in [https://github.com/mermaid-js/mermaid/pull/3415](https://togithub.com/mermaid-js/mermaid/pull/3415) - Docs/bug 3417 by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3419](https://togithub.com/mermaid-js/mermaid/pull/3419) - Docs: add '..auto generated..' to .html documentation files by [@​weedySeaDragon](https://togithub.com/weedySeaDragon) in [https://github.com/mermaid-js/mermaid/pull/3420](https://togithub.com/mermaid-js/mermaid/pull/3420) - Mention obsidian has native support for mermaid by [@​IanLee1521](https://togithub.com/IanLee1521) in [https://github.com/mermaid-js/mermaid/pull/3513](https://togithub.com/mermaid-js/mermaid/pull/3513) - docs: replace `yarn` with `pnpm` in dev guide by [@​aloisklink](https://togithub.com/aloisklink) in [https://github.com/mermaid-js/mermaid/pull/3535](https://togithub.com/mermaid-js/mermaid/pull/3535) - Corrected theme variables reference table layout by [@​marcastel](https://togithub.com/marcastel) in [https://github.com/mermaid-js/mermaid/pull/3541](https://togithub.com/mermaid-js/mermaid/pull/3541) - Working New Documentation Vitepress by [@​emersonbottero](https://togithub.com/emersonbottero) in [https://github.com/mermaid-js/mermaid/pull/3515](https://togithub.com/mermaid-js/mermaid/pull/3515) - CODE_OF_CONDUCT Uploaded by [@​swoyam2609](https://togithub.com/swoyam2609) in [https://github.com/mermaid-js/mermaid/pull/3578](https://togithub.com/mermaid-js/mermaid/pull/3578) - Automated docs spell-checking via GitHub Actions (and address all reported issues) by [@​SeanKilleen](https://togithub.com/SeanKilleen) in [https://github.com/mermaid-js/mermaid/pull/3600](https://togithub.com/mermaid-js/mermaid/pull/3600) - docs:Improved keywords in index.html by [@​aryandeelwal](https://togithub.com/aryandeelwal) in [https://github.com/mermaid-js/mermaid/pull/3579](https://togithub.com/mermaid-js/mermaid/pull/3579) - Contribution.md updates by [@​Aniket1026](https://togithub.com/Aniket1026) in [https://github.com/mermaid-js/mermaid/pull/3614](https://togithub.com/mermaid-js/mermaid/pull/3614) - docs: Add mermaid version to script URL by [@​sidharthv96](https://togithub.com/sidharthv96) in [https://github.com/mermaid-js/mermaid/pull/3596](https://togithub.com/mermaid-js/mermaid/pull/3596) #### New Contributors - [@​KarnerTh](https://togithub.com/KarnerTh) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3399](https://togithub.com/mermaid-js/mermaid/pull/3399) - [@​mrmanc](https://togithub.com/mrmanc) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3415](https://togithub.com/mermaid-js/mermaid/pull/3415) - [@​elliot-nelson](https://togithub.com/elliot-nelson) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3479](https://togithub.com/mermaid-js/mermaid/pull/3479) - [@​emersonbottero](https://togithub.com/emersonbottero) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3476](https://togithub.com/mermaid-js/mermaid/pull/3476) - [@​pje](https://togithub.com/pje) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3509](https://togithub.com/mermaid-js/mermaid/pull/3509) - [@​IanLee1521](https://togithub.com/IanLee1521) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3513](https://togithub.com/mermaid-js/mermaid/pull/3513) - [@​ashleybartlett](https://togithub.com/ashleybartlett) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3524](https://togithub.com/mermaid-js/mermaid/pull/3524) - [@​pbrolin47](https://togithub.com/pbrolin47) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3533](https://togithub.com/mermaid-js/mermaid/pull/3533) - [@​elv-nate](https://togithub.com/elv-nate) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3538](https://togithub.com/mermaid-js/mermaid/pull/3538) - [@​marcastel](https://togithub.com/marcastel) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3541](https://togithub.com/mermaid-js/mermaid/pull/3541) - [@​AndrewL-64](https://togithub.com/AndrewL-64) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3544](https://togithub.com/mermaid-js/mermaid/pull/3544) - [@​swoyam2609](https://togithub.com/swoyam2609) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3578](https://togithub.com/mermaid-js/mermaid/pull/3578) - [@​SeanKilleen](https://togithub.com/SeanKilleen) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3600](https://togithub.com/mermaid-js/mermaid/pull/3600) - [@​aryandeelwal](https://togithub.com/aryandeelwal) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3579](https://togithub.com/mermaid-js/mermaid/pull/3579) - [@​Aniket1026](https://togithub.com/Aniket1026) made their first contribution in [https://github.com/mermaid-js/mermaid/pull/3614](https://togithub.com/mermaid-js/mermaid/pull/3614) **Full Changelog**: mermaid-js/mermaid@v9.1.7...v9.2.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [x] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/BirthdayResearch/contented). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNC4xMi4wIiwidXBkYXRlZEluVmVyIjoiMzQuMTkuMCJ9--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
📑 Summary
A bunch of E2E tests have been failing under Cypress 9.7.0 due to SIGSEGV (Segmentation fault) errors. I'm guessing this is because Cypress is slowly losing compatibility with current web browsers.
Upgrading to Cypress v10.8.0 has fixed those SIGSEGV errors.
This upgrade has been attempted before, but @knsv reverted it to fix Applitools integration (see dee9cfe).
I've tested it with own Applitools account, and it seems to work!
Additionally, I've got E2E and Applitools working in GitHub Actions (although it does have some issues, so it might not be worth keeping, see below).
📏 Design Decisions
I've also fixed every other currently failing e2e test, so that CI passes.
This just needed a small change to get Cypress to continue running, even if mermaid threw an exception.
Widen flowchart width acceptable values to within 10% of 300px. On my local environment, I'm getting 283px, which is 5.5% of 300px.
(to prevent snapshots changing in-between runs)
The
.edgePath
class they were searching for no longer exists.One test was broken due to a regression in flowchart (the
arrowMarkerAbsolute
config setting no longer does anything). I've done a quick and ugly fix forflowchart-v2
, but it's still broken inflowchart
, see fix(flowchart-v2): fix arrowMarkerAbsolute=true.Applitools Configuration
I've added Applitools to the
e2e
GitHub Actions CI and it works on myaloisklink/mermaid
repo.Issues:
APPLITOOLS_API_KEY
GitHub Secret being set.This means that PRs from forks (like in this PR) will not use applitools, since GitHub prevents PRs from forks from accessing any GitHub Secret for security reasons.
develop
branch.📋 Tasks
Make sure you
develop
branch