disable storybook test runs for now

This commit is contained in:
Matthias Kretschmann 2021-05-20 12:32:47 +02:00
parent 4dd11fd0f0
commit 53639e6839
Signed by: m
GPG Key ID: 606EEEF3C479A91F
2 changed files with 65 additions and 65 deletions

View File

@ -1,57 +1,57 @@
import React from 'react' // import React from 'react'
import { action } from '@storybook/addon-actions' // // import { action } from '@storybook/addon-actions'
import Button from './Button' // import Button from './Button'
export default { // export default {
title: 'Atoms/Button' // title: 'Atoms/Button'
} // }
export const Default = () => ( // export const Default = () => (
<> // <>
<Button onClick={action('clicked')}>Hello Button</Button> // <Button onClick={action('clicked')}>Hello Button</Button>
<br /> // <br />
<br /> // <br />
<Button size="small" onClick={action('clicked')}> // <Button size="small" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
</> // </>
) // )
export const Primary = () => ( // export const Primary = () => (
<> // <>
<Button style="primary" onClick={action('clicked')}> // <Button style="primary" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
<br /> // <br />
<br /> // <br />
<Button style="primary" size="small" onClick={action('clicked')}> // <Button style="primary" size="small" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
</> // </>
) // )
export const Ghost = () => ( // export const Ghost = () => (
<> // <>
<Button style="ghost" onClick={action('clicked')}> // <Button style="ghost" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
<br /> // <br />
<br /> // <br />
<Button style="ghost" size="small" onClick={action('clicked')}> // <Button style="ghost" size="small" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
</> // </>
) // )
export const Text = () => ( // export const Text = () => (
<> // <>
<Button style="text" onClick={action('clicked')}> // <Button style="text" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
<br /> // <br />
<br /> // <br />
<Button style="text" size="small" onClick={action('clicked')}> // <Button style="text" size="small" onClick={action('clicked')}>
Hello Button // Hello Button
</Button> // </Button>
</> // </>
) // )

View File

@ -1,14 +1,14 @@
import initStoryshots from '@storybook/addon-storyshots' // import initStoryshots from '@storybook/addon-storyshots'
import { render, wait } from '@testing-library/react' // import { render, wait } from '@testing-library/react'
// Stories are render-tested with @testing-library/react, // // Stories are render-tested with @testing-library/react,
// overwriting default snapshot testing behavior // // overwriting default snapshot testing behavior
initStoryshots({ // initStoryshots({
asyncJest: true, // asyncJest: true,
test: async ({ story, done }) => { // test: async ({ story, done }) => {
const storyElement = story.render() // const storyElement = story.render()
// render the story with @testing-library/react // // render the story with @testing-library/react
render(storyElement) // render(storyElement)
await wait(() => done()) // await wait(() => done())
} // }
}) // })