@@ -225,13 +225,11 @@ void main() {
225
225
});
226
226
227
227
test ('codeifies a class from the SDK' , () {
228
- expect (docsAsHtml,
229
- contains ('<code class="prettyprint lang-dart">String</code>' ));
228
+ expect (docsAsHtml, contains ('<code>String</code>' ));
230
229
});
231
230
232
231
test ('codeifies a reference to its parameter' , () {
233
- expect (docsAsHtml,
234
- contains ('<code class="prettyprint lang-dart">value</code>' ));
232
+ expect (docsAsHtml, contains ('<code>value</code>' ));
235
233
});
236
234
237
235
test ('links to a reference to its class' , () {
@@ -292,9 +290,7 @@ void main() {
292
290
// track when the behavior changes
293
291
test ('codeifies a prefixed top-level variable an imported lib' , () {
294
292
expect (
295
- docsAsHtml,
296
- contains (
297
- '<code class="prettyprint lang-dart">css.theOnlyThingInTheLibrary</code>' ));
293
+ docsAsHtml, contains ('<code>css.theOnlyThingInTheLibrary</code>' ));
298
294
});
299
295
300
296
test ('links to a name with a single underscore' , () {
@@ -325,7 +321,7 @@ void main() {
325
321
expect (
326
322
add.oneLineDoc,
327
323
equals (
328
- 'Adds <code class="prettyprint lang-dart" >value</code> to the end of this list,\n extending the length by one.' ));
324
+ 'Adds <code>value</code> to the end of this list,\n extending the length by one.' ));
329
325
});
330
326
331
327
test (
@@ -336,17 +332,17 @@ void main() {
336
332
expect (
337
333
add.documentationAsHtml,
338
334
startsWith (
339
- '<p>Adds <code class="prettyprint lang-dart" >value</code> to the end of this list,\n extending the length by one.' ));
335
+ '<p>Adds <code>value</code> to the end of this list,\n extending the length by one.' ));
340
336
});
341
337
342
338
test ('incorrect doc references are still wrapped in code blocks' , () {
343
339
expect (incorrectReference.documentationAsHtml,
344
- '<p>This should <code class="prettyprint lang-dart" >not work</code>.</p>' );
340
+ '<p>This should <code>not work</code>.</p>' );
345
341
});
346
342
347
343
test ('no references' , () {
348
- expect (Apple .documentationAsHtml,
349
- '<p>Sample class <code class="prettyprint lang-dart" >String</code></p>' );
344
+ expect (
345
+ Apple .documentationAsHtml, '<p>Sample class <code>String</code></p>' );
350
346
});
351
347
352
348
test ('single ref to class' , () {
@@ -358,7 +354,7 @@ void main() {
358
354
expect (
359
355
thisIsAsync.documentationAsHtml,
360
356
equals (
361
- '<p>An async function. It should look like I return a <code class="prettyprint lang-dart" >Future</code>.</p>' ));
357
+ '<p>An async function. It should look like I return a <code>Future</code>.</p>' ));
362
358
});
363
359
364
360
test ('references are correct in exported libraries' , () {
@@ -368,10 +364,7 @@ void main() {
368
364
expect (resolved, isNotNull);
369
365
expect (resolved,
370
366
contains ('<a href="two_exports/BaseClass-class.html">BaseClass</a>' ));
371
- expect (
372
- resolved,
373
- contains (
374
- 'linking over to <code class="prettyprint lang-dart">Apple</code>.' ));
367
+ expect (resolved, contains ('linking over to <code>Apple</code>.' ));
375
368
});
376
369
377
370
test ('references to class and constructors' , () {
@@ -403,16 +396,14 @@ void main() {
403
396
expect (
404
397
testingCodeSyntaxInOneLiners.oneLineDoc,
405
398
equals (
406
- 'These are code syntaxes: <code class="prettyprint lang-dart" >true</code> and <code class="prettyprint lang-dart" >false</code>' ));
399
+ 'These are code syntaxes: <code>true</code> and <code>false</code>' ));
407
400
});
408
401
409
402
test ('doc comments to parameters are marked as code' , () {
410
403
Method localMethod = subForDocComments.instanceMethods
411
404
.firstWhere ((m) => m.name == 'localMethod' );
412
- expect (localMethod.documentationAsHtml,
413
- contains ('<code class="prettyprint lang-dart">foo</code>' ));
414
- expect (localMethod.documentationAsHtml,
415
- contains ('<code class="prettyprint lang-dart">bar</code>' ));
405
+ expect (localMethod.documentationAsHtml, contains ('<code>foo</code>' ));
406
+ expect (localMethod.documentationAsHtml, contains ('<code>bar</code>' ));
416
407
});
417
408
});
418
409
@@ -668,7 +659,7 @@ void main() {
668
659
expect (
669
660
thisIsAsync.documentationAsHtml,
670
661
equals (
671
- '<p>An async function. It should look like I return a <code class="prettyprint lang-dart" >Future</code>.</p>' ));
662
+ '<p>An async function. It should look like I return a <code>Future</code>.</p>' ));
672
663
});
673
664
674
665
test ('docs do not lose brackets in code blocks' , () {
0 commit comments