test_screenshot 0.0.2 copy "test_screenshot: ^0.0.2" to clipboard
test_screenshot: ^0.0.2 copied to clipboard

Take screenshots during your unit tests or integration tests

Take screenshots during your unit tests or integration tests.

usage #

  • Wrap your widget tree with a Screenshotter widget
  • call tester.screenshot()
  • profit
  testWidgets('should create a screenshot', (tester) async {
    await tester.pumpWidget(
      Screenshotter(
        child: MaterialApp(
          home: Scaffold(body: Center(child: Icon(Icons.home))),
        ),
      ),
    );

    await tester.screenshot(path: file.path);
  });
7
likes
0
points
1.14k
downloads

Publisher

unverified uploader

Weekly Downloads

Take screenshots during your unit tests or integration tests

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, flutter_test, image

More

Packages that depend on test_screenshot