nathanbaleeta / ureport_mobile

U-Report is a social messaging tool and data collection system developed by UNICEF to improve citizen engagement, inform leaders, and foster positive change. The program sends polls and alerts to its participants, collecting real-time responses, and subsequently publishes gathered data.
https://ureport.in/
GNU General Public License v3.0
6 stars 1 forks source link

Write widget test for top navigation using tabs #7

Closed nathanbaleeta closed 4 years ago

nathanbaleeta commented 4 years ago

To ensure theU-Report app continues to work as developers add more features or change existing functionality, writing tests for every custom built widget should be an integral part of the development process.

Unit tests are handy for verifying the behavior of a single function, method, or class. The test package provides the core framework for writing unit tests, and the flutter_test package provides additional utilities for testing widgets.

Carry out following steps to add a widget test for the tog navigation widget:

Hints: https://medium.com/flutterpub/writing-and-running-widget-tests-from-android-studio-d63b9fea21c5 https://flutter.dev/docs/cookbook/testing/unit/introduction

nathanbaleeta commented 4 years ago

Removed widget test for DefaultTabController tab-pressing callback validation to avoid tests for the tab views failing in the future.