storybook/cypress/generated/addon-docs.spec.ts
2021-09-24 13:15:08 +08:00

17 lines
406 B
TypeScript

describe('addon-action', () => {
before(() => {
cy.visitStorybook();
});
it('should have docs tab', () => {
cy.navigateToStory('example-button', 'primary');
cy.viewAddonTab('Docs');
// MDX rendering
cy.getDocsElement().find('h1').should('contain.text', 'Button');
// inline story rendering
cy.getDocsElement().find('button').should('contain.text', 'Button');
});
});