@@ -649,7 +649,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
649
649
];
650
650
expect (analytics.userPropertyMap.keys.length, userPropertyKeys.length,
651
651
reason: 'There should only be ${userPropertyKeys .length } keys' );
652
- for (var key in userPropertyKeys) {
652
+ for (final key in userPropertyKeys) {
653
653
expect (analytics.userPropertyMap.keys.contains (key), true ,
654
654
reason: 'The $key variable is required' );
655
655
}
@@ -944,7 +944,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
944
944
secondAnalytics! .send (testEvent);
945
945
946
946
// Query the log file stats to verify that there are two tools
947
- var query = analytics.logFileStats ()! ;
947
+ final query = analytics.logFileStats ()! ;
948
948
949
949
expect (query.toolCount, {'flutter-tool' : 1 , 'dart-tool' : 1 },
950
950
reason: 'There should have been two tools in the persisted logs' );
@@ -1048,7 +1048,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
1048
1048
secondAnalytics! .send (testEvent);
1049
1049
1050
1050
// Query the log file stats to verify that there are two tools
1051
- var query = analytics.logFileStats ()! ;
1051
+ final query = analytics.logFileStats ()! ;
1052
1052
1053
1053
expect (query.toolCount, {'dart-tool' : 1 },
1054
1054
reason: 'There should have only been on tool that sent events' );
@@ -1059,7 +1059,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
1059
1059
// Sending a query with the first analytics instance which has flutter information
1060
1060
// available should reflect in the query that there is 1 flutter channel present
1061
1061
analytics.send (testEvent);
1062
- LogFileStats ? query2 = analytics.logFileStats ()! ;
1062
+ final query2 = analytics.logFileStats ()! ;
1063
1063
1064
1064
expect (query2.toolCount, {'dart-tool' : 1 , 'flutter-tool' : 1 },
1065
1065
reason: 'Two different analytics instances have '
@@ -1098,7 +1098,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
1098
1098
1099
1099
var userPropLengthValid = true ;
1100
1100
final invalidUserProps = < String > [];
1101
- for (var key in userPropPayload.keys) {
1101
+ for (final key in userPropPayload.keys) {
1102
1102
if (key.length > maxUserPropLength) {
1103
1103
userPropLengthValid = false ;
1104
1104
invalidUserProps.add (key);
@@ -1117,7 +1117,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
1117
1117
final toolLabelPattern = RegExp (r'^[a-zA-Z][a-zA-Z\_-]{0,35}$' );
1118
1118
var toolLengthValid = true ;
1119
1119
final invalidTools = < DashTool > [];
1120
- for (var tool in DashTool .values) {
1120
+ for (final tool in DashTool .values) {
1121
1121
if (! toolLabelPattern.hasMatch (tool.label)) {
1122
1122
toolLengthValid = false ;
1123
1123
invalidTools.add (tool);
@@ -1137,7 +1137,7 @@ ${initialTool.label}=$dateStamp,$toolsMessageVersion
1137
1137
final eventLabelPattern = RegExp (r'^[a-zA-Z]{1}[a-zA-Z0-9\_]{0,39}$' );
1138
1138
var eventValid = true ;
1139
1139
final invalidEvents = < DashEvent > [];
1140
- for (var event in DashEvent .values) {
1140
+ for (final event in DashEvent .values) {
1141
1141
if (! eventLabelPattern.hasMatch (event.label)) {
1142
1142
eventValid = false ;
1143
1143
invalidEvents.add (event);
0 commit comments