Fix misspelling in tab description (#15449)
Actual text: "Tab 2 of $3" Expected text: "Tab 2 of 3"
This commit is contained in:
parent
b0f7da9249
commit
2609876c8f
@ -284,7 +284,7 @@ class GlobalMaterialLocalizations implements MaterialLocalizations {
|
|||||||
final String template = _translationBundle.tabLabel;
|
final String template = _translationBundle.tabLabel;
|
||||||
return template
|
return template
|
||||||
.replaceFirst(r'$tabIndex', formatDecimal(tabIndex))
|
.replaceFirst(r'$tabIndex', formatDecimal(tabIndex))
|
||||||
.replaceFirst(r'tabCount', formatDecimal(tabCount));
|
.replaceFirst(r'$tabCount', formatDecimal(tabCount));
|
||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
|
@ -82,8 +82,8 @@ void main() {
|
|||||||
expect(localizations.pageRowsInfoTitle(1, 10, 100, false), isNot(contains(r'$rowCount')));
|
expect(localizations.pageRowsInfoTitle(1, 10, 100, false), isNot(contains(r'$rowCount')));
|
||||||
|
|
||||||
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNotNull);
|
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNotNull);
|
||||||
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNot(contains('tabIndex')));
|
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNot(contains(r'$tabIndex')));
|
||||||
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNot(contains('tabCount')));
|
expect(localizations.tabLabel(tabIndex: 2, tabCount: 5), isNot(contains(r'$tabCount')));
|
||||||
expect(() => localizations.tabLabel(tabIndex: 0, tabCount: 5), throwsAssertionError);
|
expect(() => localizations.tabLabel(tabIndex: 0, tabCount: 5), throwsAssertionError);
|
||||||
expect(() => localizations.tabLabel(tabIndex: 2, tabCount: 0), throwsAssertionError);
|
expect(() => localizations.tabLabel(tabIndex: 2, tabCount: 0), throwsAssertionError);
|
||||||
});
|
});
|
||||||
|
Loading…
x
Reference in New Issue
Block a user