```js
// MyComponent.spec.js

describe('My Component', () => {
  it('should respond to click on button with warning', () => {
	cy.visit('http://localhost:6006/iframe.html?id=my-component--basic-story’);
	cy.get('#button').click();
	cy.get('#warning').should('contain.text', 'You need to fill in the form!');
  });
})
```