File tree Expand file tree Collapse file tree 1 file changed +29
-0
lines changed
google_api_availability_platform_interface/test Expand file tree Collapse file tree 1 file changed +29
-0
lines changed Original file line number Diff line number Diff line change 1+ import 'package:flutter_test/flutter_test.dart' ;
2+ import 'package:google_api_availability_platform_interface/google_api_availability_platform_interface.dart' ;
3+
4+ void main () {
5+ group ('$GooglePlayServicesAvailability ' , () {
6+ test ('has the right amount of availability states' , () {
7+ const values = GooglePlayServicesAvailability .values;
8+
9+ expect (values.length, 8 );
10+ });
11+
12+ test ('check if corresponding status gets received when calling constructor' ,
13+ () {
14+ const values = GooglePlayServicesAvailability .values;
15+
16+ for (var i = 0 ; i < values.length; i++ ) {
17+ expect (values[i], GooglePlayServicesAvailability .byValue (i));
18+ }
19+ });
20+
21+ test ('check if toString method returns the corresponding name' , () {
22+ var playServicesAvailability =
23+ const GooglePlayServicesAvailability .private (0 );
24+
25+ expect (playServicesAvailability.toString (),
26+ 'GooglePlayServicesAvailability.success' );
27+ });
28+ });
29+ }
You can’t perform that action at this time.
0 commit comments