The current Flutter Driver tests will be deprecated and it’s recommended to move to the new Integration Tests.

In this post let’s talk about what are the new tests good at and what are they still lacking.

The Positives

+ Same API

The API does not only look but is the same that is used…


Photo by Caspar Camille Rubin on Unsplash

TL;DR: Follow those steps if you want to run Flutter as a desktop application on beta or stable channels (and not only on master or dev).

At the time of writing this post, Flutter Desktop is still in Alpha and you are only allowed to enable it on master or…


Photo by Nynne Schrøder on Unsplash

TL;DR You can now write fast driver tests with much less amount of code using this package.

A note of warning: if you are in a Flutter project that won’t take more than 3 months, you won’t need an extensive testing approach, therefore you won’t need the approach that I…


Photo by amirali mirhashemian on Unsplash

SliverFillRemaining is fairly simple yet useful — it fills the remaining scrollable space with a widget of your choice.


Photo by amirali mirhashemian on Unsplash

The best way to learn how to write your own Sliver is to know how existing Slivers are made.

I would split Slivers into groups by their complexity:

Easy

Single child Slivers


Flutter Animations Cheat Sheet

Since writing Flutter Layout Cheat Sheet article, I intended to create a similar article about Flutter’s animations.
Unfortunately using GIFs or videos is not the greatest way to show the potential of animations. I was not able to teach animations compellingly… until now, thanks to Flutter Web.

If you want…


Photo by Johan Desaeyere on Unsplash

Creating animations in Flutter is really fun and easy, but there is one bad practice that might make those animations laggy: setState.

Bad Practice: AnimationController and setState

When using AnimationController in a StatefulWidget, you might be tempted to do the following:

void initState() {
_controller = AnimationController(
vsync: this,
duration: Duration(seconds: 1),
)
..addListener(()


Photo by Debby Hudson on Unsplash

TL;DR: Widget Keys can improve the performance of our application in places where you do not get the promised 60 FPS.

An Element is created internally by a Widget. Its main purpose is to know where in the widget tree is the widget that created it.

Elements are expensive to…


TL;DR Flutter provides a reliable and easy way to test custom widgets and painters using snapshot/golden files testing.

The Issue with Testing Custom Painted Widgets

Widget tests are an amazing way to verify if your Widgets are working correctly. Unfortunately, they don’t work so well when you just paint your own widgets with CustomPainter .

Golden Files/Snapshots to the rescue!

Golden files

Tomek Polański

Passionate mobile developer. One thing I like more than learning new things: sharing them

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store