@@ -48,37 +48,41 @@ class TaskIcon extends StatelessWidget {
48
48
);
49
49
}
50
50
51
- if (qualifiedTask.task! .toLowerCase ().contains ('_fuchsia' )) {
51
+ final String matchedName = qualifiedTask.task! .toLowerCase ();
52
+ final bool isWebTest = matchedName.contains ('_web' ) || matchedName.contains ('web_' );
53
+ final bool isToolTest = matchedName.contains ('_tool' ) || matchedName.contains ('tool_' );
54
+
55
+ if (matchedName.contains ('_fuchsia' )) {
52
56
return Padding (
53
57
padding: const EdgeInsets .all (2.0 ),
54
58
child: Image .asset (
55
59
'assets/fuchsia.png' ,
56
60
color: blendFilter,
57
61
),
58
62
);
59
- } else if (qualifiedTask.task ! . toLowerCase (). contains ( '_web' ) ) {
63
+ } else if (isWebTest && ! isToolTest ) {
60
64
return Padding (
61
65
padding: const EdgeInsets .all (2.0 ),
62
66
child: Image .asset (
63
67
'assets/chromium.png' ,
64
68
color: blendFilter,
65
69
),
66
70
);
67
- } else if (qualifiedTask.task ! . toLowerCase () .contains ('_android' )) {
71
+ } else if (matchedName .contains ('_android' )) {
68
72
return Icon (
69
73
Icons .android,
70
74
color: blendFilter,
71
75
);
72
- } else if (qualifiedTask.task ! . toLowerCase () .startsWith ('linux' )) {
76
+ } else if (matchedName .startsWith ('linux' )) {
73
77
return Padding (
74
78
padding: const EdgeInsets .all (2.0 ),
75
79
child: Image .asset (
76
80
'assets/linux.png' ,
77
81
color: blendFilter,
78
82
),
79
83
);
80
- } else if (qualifiedTask.task ! . toLowerCase () .startsWith ('mac' )) {
81
- if (qualifiedTask.task ! . toLowerCase () .contains ('_ios' )) {
84
+ } else if (matchedName .startsWith ('mac' )) {
85
+ if (matchedName .contains ('_ios' )) {
82
86
return Icon (
83
87
Icons .phone_iphone,
84
88
color: blendFilter,
@@ -92,7 +96,7 @@ class TaskIcon extends StatelessWidget {
92
96
),
93
97
);
94
98
}
95
- } else if (qualifiedTask.task ! . toLowerCase () .startsWith ('win' )) {
99
+ } else if (matchedName .startsWith ('win' )) {
96
100
return Image .asset (
97
101
'assets/windows.png' ,
98
102
color: blendFilter,
0 commit comments