@@ -4068,6 +4068,7 @@ String topLevelFunction(int param1, bool param2, Cool coolBeans,
40684068 TopLevelVariable nodocGetter, nodocSetter;
40694069 TopLevelVariable complicatedReturn;
40704070 TopLevelVariable meaningOfLife, importantComputations;
4071+ TopLevelVariable genericTypedefCombo;
40714072
40724073 setUpAll (() {
40734074 v = exLibrary.properties.firstWhere ((p) => p.name == 'number' );
@@ -4090,6 +4091,19 @@ String topLevelFunction(int param1, bool param2, Cool coolBeans,
40904091 fakeLibrary.properties.firstWhere ((p) => p.name == 'setAndGet' );
40914092 mapWithDynamicKeys = fakeLibrary.properties
40924093 .firstWhere ((p) => p.name == 'mapWithDynamicKeys' );
4094+ genericTypedefCombo = fakeLibrary.properties
4095+ .firstWhere ((p) => p.name == 'genericTypedefCombo' );
4096+ });
4097+
4098+ test (
4099+ 'Verify that combos with a generic typedef modelType can render correctly' ,
4100+ () {
4101+ // TODO(jcollins-g): After analyzer 2.0.0, this can be `isEmpty`.
4102+ expect (genericTypedefCombo.modelType.typeArguments, isNotNull);
4103+ expect (
4104+ genericTypedefCombo.modelType.linkedName,
4105+ equals (
4106+ '<a href=\" %%__HTMLBASE_dartdoc_internal__%%fake/NewGenericTypedef.html\" >NewGenericTypedef</a>' ));
40934107 });
40944108
40954109 test ('Verify that final and late show up (or not) appropriately' , () {
@@ -4554,9 +4568,9 @@ String topLevelFunction(int param1, bool param2, Cool coolBeans,
45544568 expect (
45554569 oldgeneric.modelType.linkedName,
45564570 isIn ([
4571+ 'T Function<span class="signature">(<span class="parameter" id="GenericTypedef-param-input"><span class="type-annotation">T</span> <span class="parameter-name">input</span></span>)</span>' ,
4572+ // Remove following after analyzer 2.0.0
45574573 'T Function<span class="signature">(<span class="parameter" id="param-input"><span class="type-annotation">T</span> <span class="parameter-name">input</span></span>)</span>' ,
4558- // Remove below option after analyzer 1.6.0.
4559- 'Function(<span class=\" parameter\" id=\" GenericTypedef-param-input\" ><span class=\" type-annotation\" >T</span></span>) → T'
45604574 ]));
45614575 expect (
45624576 generic.modelType.linkedName,
0 commit comments