storybook_toolkit_tester

Creator: coderz1093

Last updated:

0 purchases

storybook_toolkit_tester Image
storybook_toolkit_tester Images

Languages

Categories

Add to Cart

Description:

storybook toolkit tester

Storybook Toolkit Tester #
Setup: #


Import storybook_toolkit_tester package:
dev_dependencies:
storybook_toolkit_tester: ^1.2.0
copied to clipboard


Create test file, e.g. storybook_test.dart.


Add the following content there:
void main() => testStorybook(
storybook,
devices: { Devices.ios.iPhoneSE, Devices.android.pixel4, Devices.ios.iPadAir4 },
filterStories: (Story story) {
final skipStories = [];
return !skipStories.contains(story.name);
},
);

final storybook = Storybook(
stories: [
Story(
name: 'Button',
builder: (context) => ElevatedButton(
onPressed: () {},
child: const Text('Button'),
),
),
Story(
name: 'CounterPage',
builder: (context) => const CounterPage(),
),
],
);
copied to clipboard


Generate golden images by running: flutter test --update-goldens --tags=storybook.

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.