mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-08-19 08:16:42 +02:00
feat: add hideUnusedParticipants and some cleanup
This commit is contained in:
@@ -18,7 +18,7 @@ export const mermaidUrl = (graphStr, options, api) => {
|
||||
return url;
|
||||
};
|
||||
|
||||
export const imgSnapshotTest = (graphStr, _options, api) => {
|
||||
export const imgSnapshotTest = (graphStr, _options, api = false, validation) => {
|
||||
cy.log(_options);
|
||||
const options = Object.assign(_options);
|
||||
if (!options.fontFamily) {
|
||||
@@ -46,8 +46,8 @@ export const imgSnapshotTest = (graphStr, _options, api) => {
|
||||
const url = mermaidUrl(graphStr, options, api);
|
||||
|
||||
cy.visit(url);
|
||||
if (validation) cy.get('svg').should(validation);
|
||||
cy.get('svg');
|
||||
// cy.percySnapshot();
|
||||
// Default name to test title
|
||||
const name = (options.name || cy.state('runnable').fullTitle()).replace(/\s+/g, '-');
|
||||
|
||||
|
Reference in New Issue
Block a user