Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
flutter tests don't compile anymore since the last update #24384
Since today's flutter upgrade, the unit tests in the
Here is the dependency in my
It worked fine yesterday, so where is the problem ?
And I've also tried reinstalling flutter manually, deleting completely my ~/flutter folder and replacing it with the content of
I can still develop my app but I can't run my tests anymore, so that's quite annoying.
What can I do to solve this problem ?
Just found a workaround :)
I guess this sudden compilation problem has to do with the #23755 change described on
May I kindly suggest that each time you release an upgrade which will break the builds, you also suggest a workaround on this web page ?
I also suggest you fix this web page, as the first example is now obsolete :
We announced this change via flutter-dev and the changelog:
All you need to do to keep your tests working as before is add a dependency on package:test. In general, if you are using a package it should be in your pubspec.
Thanks for the quick answer :D
Maybe the problem here was that the google team supposes that every Flutter developer out there is reading every bit of information that is published in the google groups, on stack overflow, etc.
That's not the way it is for most of us...
We all have lot of work to do, and generally not the time we asked to do it, and we search for a solution in the google groups and on stack overflow only when we need to, because otherwise we use our development time to implement what we are paid for.
And that's the first reason we decided to switch to flutter by the way : it significantly increases our productivity, allowing to develop better cross-platform applications, faster.
And yes, we know it's not a stable 1.0 library, so we expect some breaking changes from time to time, even if like everybody I don't like to have my code stop compiling right after an upgrade.
Believe me, I appreciate A LOT that the Google management has decided to allow us to use your in-house technology for our own needs. That's very generous from you !
But may I still suggest that when such breaking change happen, you not only mention it on "https://github.com/flutter/flutter/wiki/Changelog", but also clearly suggest a solution or even just a workaround, on that same page, so we don't have to hunt for a possible solution in the mailing lists, on stack overflow, etc... :)