mirror of
				https://github.com/mermaid-js/mermaid.git
				synced 2025-11-04 12:54:08 +01:00 
			
		
		
		
	fix uncaughexception in tests
This commit is contained in:
		@@ -1,6 +1,15 @@
 | 
			
		||||
import { imgSnapshotTest } from '../../helpers/util';
 | 
			
		||||
 | 
			
		||||
describe('Error Diagrams', () => {
 | 
			
		||||
  beforeEach(() => {
 | 
			
		||||
    cy.on('uncaught:exception', (err) => {
 | 
			
		||||
      expect(err.message).to.include('Parse error');
 | 
			
		||||
      // return false to prevent the error from
 | 
			
		||||
      // failing this test
 | 
			
		||||
      return false;
 | 
			
		||||
    });
 | 
			
		||||
  });
 | 
			
		||||
 | 
			
		||||
  it('should render a simple ER diagram', () => {
 | 
			
		||||
    imgSnapshotTest(
 | 
			
		||||
      `
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user