Run tests using IntelliJ or VSCode

The Flutter plugins for IntelliJ and VSCode support running tests.
This is often the best option while writing tests because it provides the
fastest feedback loop as well as the ability to set breakpoints.

IntelliJ
    
      Open the counter_test.dart file
      Select the Run menu
      Click the Run 'tests in counter_test.dart' option
      Alternatively, use the appropriate keyboard shortcut
for your platform.

VSCode
    
      Open the counter_test.dart file
      Select the Run menu
      Click the Start Debugging option
      Alternatively, use the appropriate keyboard shortcut
for your platform.

Run tests in a terminal

You can also use a terminal to run the tests by executing the following
command from the root of the project:

For more options regarding unit tests, you can execute this command:

Performance profiling

Mock dependencies using Mockito