CPSC270A
Software Eng & Project Design

Activity 17

Test Count Widget

Create widget tests for the count app.

Details

The app should build off of the app from a previous activities that used state to count button presses by adding the following:

  1. a file that runs widget tests for the count text.

  2. a widget test for:

    1. the count initially being 0.

    2. the count being 1 after a single tap

    3. the count being 2 after two taps.

Example

$ flutter test test/count_widget_test.dart
00:07 +3: All tests passed!