4 writes to Content
Microsoft.AspNetCore.Mvc.Razor.Test (3)
RazorPageTest.cs (3)
298
outputLevel1.
Content
= await outputLevel1.GetChildContentAsync();
346
outputLevel2.
Content
= await outputLevel2.GetChildContentAsync();
362
outputLevel1.
Content
= await outputLevel1.GetChildContentAsync();
Microsoft.AspNetCore.Razor.Test (1)
TagHelpers\TagHelperOutputTest.cs (1)
33
Content
= initialOutputChildContent,
210 references to Content
BasicWebSite (1)
RequestScopedTagHelper.cs (1)
19
output.
Content
.SetContent(RequestIdService.RequestId);
ControllersFromServicesWebSite (1)
TagHelpers\InServicesTagHelper.cs (1)
22
output.
Content
.SetContent(_value.Value.ToString(CultureInfo.InvariantCulture));
Microsoft.AspNetCore.Mvc.TagHelpers (14)
CacheTagHelper.cs (1)
87
output.
Content
.SetHtmlContent(content);
ComponentTagHelper.cs (1)
104
output.
Content
.SetHtmlContent(result);
DistributedCacheTagHelper.cs (1)
73
output.
Content
.SetHtmlContent(content);
InputTagHelper.cs (1)
269
output.
Content
.AppendHtml(tagBuilder.InnerHtml);
LabelTagHelper.cs (2)
78
output.
Content
.SetHtmlContent(tagBuilder.InnerHtml);
83
output.
Content
.SetHtmlContent(childContent);
LinkTagHelper.cs (1)
299
output.
Content
.SetHtmlContent(HtmlString.Empty);
OptionTagHelper.cs (1)
106
childContent = output.
Content
;
PartialTagHelper.cs (1)
145
output.
Content
.SetHtmlContent(viewBuffer);
PersistComponentStateTagHelper.cs (1)
57
output.
Content
.SetHtmlContent(content);
ScriptTagHelper.cs (2)
258
output.
Content
.SetHtmlContent(importMap.ToString());
312
output.
Content
.SetContent(string.Empty);
TextAreaTagHelper.cs (1)
97
output.
Content
.SetHtmlContent(tagBuilder.InnerHtml);
ValidationMessageTagHelper.cs (1)
101
output.
Content
.SetHtmlContent(tagBuilder.InnerHtml);
Microsoft.AspNetCore.Mvc.TagHelpers.Test (167)
AnchorTagHelperTest.cs (14)
49
output.
Content
.SetContent("Something");
83
Assert.Equal("Something", output.
Content
.GetContent());
106
output.
Content
.SetContent(string.Empty);
134
Assert.Empty(output.
Content
.GetContent());
156
output.
Content
.SetContent(string.Empty);
186
Assert.Empty(output.
Content
.GetContent());
208
output.
Content
.SetContent(string.Empty);
244
Assert.Empty(output.
Content
.GetContent());
266
output.
Content
.SetContent(string.Empty);
303
Assert.Empty(output.
Content
.GetContent());
325
output.
Content
.SetContent(string.Empty);
361
Assert.Empty(output.
Content
.GetContent());
383
output.
Content
.SetContent(string.Empty);
434
output.
Content
.SetContent(string.Empty);
CacheTagHelperTest.cs (25)
56
Assert.Equal(childContent, tagHelperOutput.
Content
.GetContent());
86
Assert.Equal(childContent, tagHelperOutput.
Content
.GetContent());
115
Assert.Equal(childContent, tagHelperOutput1.
Content
.GetContent());
137
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
165
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
187
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
248
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
350
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
372
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
403
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
425
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
456
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
478
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
525
Assert.Equal("HtmlEncode[[some-content]]", tagHelperOutput.
Content
.GetContent());
612
Assert.Equal(childContent, tagHelperOutput1.
Content
.GetContent());
617
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
695
Assert.Empty(tagHelperOutput1.
Content
.GetContent());
700
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
759
Assert.Empty(tagHelperOutput1.
Content
.GetContent());
771
Assert.Empty(tagHelperOutput2.
Content
.GetContent());
783
Assert.Equal(childContent, tagHelperOutput3.
Content
.GetContent());
795
Assert.Equal(childContent, tagHelperOutput4.
Content
.GetContent());
842
Assert.Equal(encoder.Encode(expected), tagHelperOutput1.
Content
.GetContent());
925
Assert.Equal(encoder.Encode(expected), tagHelperOutput1.
Content
.GetContent());
926
Assert.Equal(encoder.Encode(expected), tagHelperOutput2.
Content
.GetContent());
ComponentTagHelperTest.cs (1)
40
var content = await prerenderer.Dispatcher.InvokeAsync(() => HtmlContentUtilities.HtmlContentToString(output.
Content
));
DistributedCacheTagHelperTest.cs (16)
63
Assert.Equal(childContent, tagHelperOutput.
Content
.GetContent());
109
Assert.Equal(childContent, tagHelperOutput.
Content
.GetContent());
158
Assert.Equal(childContent, tagHelperOutput1.
Content
.GetContent());
183
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
217
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
241
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
380
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
404
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
442
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
466
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
504
Assert.Equal(childContent1, tagHelperOutput1.
Content
.GetContent());
528
Assert.Equal(childContent2, tagHelperOutput2.
Content
.GetContent());
615
Assert.Equal(childContent, tagHelperOutput1.
Content
.GetContent());
620
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
707
Assert.Empty(tagHelperOutput1.
Content
.GetContent());
712
Assert.Equal(childContent, tagHelperOutput2.
Content
.GetContent());
EnvironmentTagHelperTest.cs (2)
148
Assert.True(output.
Content
.GetContent().Length == 0);
181
Assert.True(output.
Content
.GetContent().Length == 0);
FormActionTagHelperTest.cs (4)
251
Assert.Empty(output.
Content
.GetContent());
309
Assert.Empty(output.
Content
.GetContent());
382
Assert.Empty(output.
Content
.GetContent());
435
Assert.Empty(output.
Content
.GetContent());
FormTagHelperTest.cs (13)
120
Assert.True(output.
Content
.GetContent().Length == 0);
174
Assert.True(output.
Content
.GetContent().Length == 0);
231
Assert.Empty(output.
Content
.GetContent());
289
Assert.Empty(output.
Content
.GetContent());
364
Assert.True(output.
Content
.GetContent().Length == 0);
428
Assert.True(output.
Content
.GetContent().Length == 0);
499
Assert.True(output.
Content
.GetContent().Length == 0);
552
Assert.True(output.
Content
.GetContent().Length == 0);
676
Assert.True(output.
Content
.GetContent().Length == 0);
733
Assert.True(output.
Content
.GetContent().Length == 0);
791
Assert.True(output.
Content
.GetContent().Length == 0);
845
Assert.True(output.
Content
.GetContent().Length == 0);
1002
Assert.True(output.
Content
.GetContent().Length == 0);
ImageTagHelperTest.cs (4)
157
Assert.True(output.
Content
.GetContent().Length == 0);
209
Assert.True(output.
Content
.GetContent().Length == 0);
252
Assert.True(output.
Content
.GetContent().Length == 0);
284
Assert.True(output.
Content
.GetContent().Length == 0);
InputTagHelperTest.cs (24)
97
output.
Content
.AppendHtml(originalContent);
106
Assert.Equal(originalContent, HtmlContentUtilities.HtmlContentToString(output.
Content
));
144
output.
Content
.AppendHtml(content);
191
output.
Content
.AppendHtml(content);
235
output.
Content
.AppendHtml(content);
243
Assert.Equal(content, HtmlContentUtilities.HtmlContentToString(output.
Content
));
662
output.
Content
.SetContent(expectedContent);
688
Assert.Equal(expectedContent, output.
Content
.GetContent());
759
Assert.Empty(output.
Content
.GetContent());
830
Assert.Empty(output.
Content
.GetContent());
1175
output.
Content
.AppendHtml(originalContent);
1211
Assert.Equal(originalContent, HtmlContentUtilities.HtmlContentToString(output.
Content
));
1275
output.
Content
.SetContent(expectedContent);
1317
Assert.Equal(expectedContent, output.
Content
.GetContent());
1441
output.
Content
.SetContent(expectedContent);
1482
Assert.Equal(expectedContent, output.
Content
.GetContent());
1541
output.
Content
.SetContent(expectedContent);
1577
Assert.Equal(expectedContent, output.
Content
.GetContent());
1653
output.
Content
.SetContent(expectedContent);
1695
Assert.Equal(expectedContent, output.
Content
.GetContent());
1811
Assert.Equal(string.Empty, output.
Content
.GetContent());
1880
Assert.Equal(string.Empty, output.
Content
.GetContent());
1949
Assert.Equal(string.Empty, output.
Content
.GetContent());
2043
Assert.Equal(string.Empty, output.
Content
.GetContent());
LabelTagHelperTest.cs (3)
208
output.
Content
.AppendHtml(tagHelperOutputContent.OriginalContent);
222
HtmlContentUtilities.HtmlContentToString(output.
Content
));
328
Assert.Equal(expectedContent, HtmlContentUtilities.HtmlContentToString(output.
Content
));
LinkTagHelperTest.cs (1)
406
Assert.True(output.
Content
.GetContent().Length == 0);
OptionTagHelperTest.cs (6)
417
output.
Content
.SetContent(originalContent);
437
Assert.Equal(expectedTagHelperOutput.
Content
.GetContent(), output.
Content
.GetContent());
488
output.
Content
.SetContent(originalContent);
553
output.
Content
.SetContent(originalContent);
577
tagHelperOutput.
Content
.SetContent(content);
PartialTagHelperTest.cs (8)
182
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
223
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
264
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
306
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
642
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
692
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
788
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
834
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
, new HtmlTestEncoder());
PersistComponentStateTagHelperTest.cs (7)
49
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
71
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
99
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
129
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
159
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
183
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
212
var content = HtmlContentUtilities.HtmlContentToString(output.
Content
);
ScriptTagHelperTest.cs (3)
382
Assert.True(output.
Content
.GetContent().Length == 0);
751
Assert.Equal(importMap.ToJson(), output.
Content
.GetContent());
794
Assert.Equal(importMap.ToJson(), output.
Content
.GetContent());
SelectTagHelperTest.cs (8)
217
output.
Content
.SetContent(expectedContent);
242
Assert.Equal(expectedContent, output.
Content
.GetContent());
307
output.
Content
.AppendHtml(expectedContent);
341
Assert.Equal(expectedContent, output.
Content
.GetContent());
398
output.
Content
.AppendHtml(expectedContent);
422
Assert.Equal(expectedContent, output.
Content
.GetContent());
487
output.
Content
.AppendHtml(expectedContent);
521
Assert.Equal(expectedContent, output.
Content
.GetContent());
TextAreaTagHelperTest.cs (3)
142
output.
Content
.SetContent("original content");
153
Assert.Equal(expectedContent, HtmlContentUtilities.HtmlContentToString(output.
Content
));
228
Assert.Equal(expectedContent, HtmlContentUtilities.HtmlContentToString(output.
Content
));
ValidationMessageTagHelperTest.cs (9)
60
output.
Content
.SetContent(expectedContent);
83
Assert.Equal(expectedContent, output.
Content
.GetContent());
274
output.
Content
.SetContent(expectedContent);
286
Assert.Equal(expectedContent, output.
Content
.GetContent());
329
output.
Content
.AppendHtml(outputContent);
351
Assert.Equal(expectedOutputContent, output.
Content
.GetContent());
413
Assert.Equal(expectedOutputContent, output.
Content
.GetContent());
431
output.
Content
.SetContent(expectedContent);
451
Assert.Equal(expectedContent, output.
Content
.GetContent());
ValidationSummaryTagHelperTest.cs (16)
71
output.
Content
.SetContent(expectedContent);
88
Assert.Equal(expectedContent, output.
Content
.GetContent());
239
output.
Content
.SetContent(expectedContent);
262
Assert.Equal(expectedContent, output.
Content
.GetContent());
309
output.
Content
.SetContent(expectedContent);
327
Assert.Equal(expectedContent, output.
Content
.GetContent());
370
output.
Content
.SetContent(expectedContent);
388
Assert.Equal(expectedContent, output.
Content
.GetContent());
425
output.
Content
.SetContent(expectedContent);
460
Assert.Equal(expectedContent, output.
Content
.GetContent());
484
output.
Content
.SetContent(expectedContent);
503
Assert.Equal(expectedContent, output.
Content
.GetContent());
540
output.
Content
.SetContent(expectedContent);
559
Assert.Equal(expectedContent, output.
Content
.GetContent());
625
output.
Content
.SetContent(expectedContent);
640
Assert.Equal(expectedContent, output.
Content
.GetContent());
Microsoft.AspNetCore.Razor (2)
TagHelpers\TagHelperOutput.cs (2)
154
/// <c>true</c> if <see cref="
Content
"/> has been set, <c>false</c> otherwise.
204
/// <see cref="
Content
"/>, <see cref="PostContent"/>, and <see cref="PostElement"/> to suppress output.
Microsoft.AspNetCore.Razor.Runtime (3)
Runtime\TagHelpers\TagHelperExecutionContext.cs (3)
200
/// sets <see cref="Output"/>'s <see cref="TagHelperOutput.
Content
"/> to the rendered results.
203
/// <see cref="TagHelperOutput.
Content
"/> to the children's rendered content.</returns>
223
Output.
Content
.SetHtmlContent(childContent);
Microsoft.AspNetCore.Razor.Runtime.Test (1)
Runtime\TagHelpers\TagHelperExecutionContextTest.cs (1)
84
Assert.Equal(content, executionContext.Output.
Content
.GetContent());
Microsoft.AspNetCore.Razor.Test (15)
TagHelpers\TagHelperOutputTest.cs (15)
215
Assert.NotNull(tagHelperOutput.
Content
);
233
Assert.NotNull(tagHelperOutput.
Content
);
274
Assert.NotNull(tagHelperOutput.
Content
);
287
tagHelperOutput.
Content
.SetContent("Hello World");
292
Assert.NotNull(tagHelperOutput.
Content
);
297
tagHelperOutput.
Content
.GetContent(new HtmlTestEncoder()));
310
Assert.NotNull(tagHelperOutput.
Content
);
324
tagHelperOutput.
Content
.Append("Content");
336
Assert.NotNull(tagHelperOutput.
Content
);
337
Assert.Empty(tagHelperOutput.
Content
.GetContent(new HtmlTestEncoder()));
357
tagHelperOutput.
Content
.Append("Content");
368
Assert.NotNull(tagHelperOutput.
Content
);
369
Assert.Empty(tagHelperOutput.
Content
.GetContent(new HtmlTestEncoder()));
1082
Assert.Equal(string.Empty, output.
Content
.GetContent());
1121
output.
Content
.AppendHtml(content);
TagHelpersWebSite (6)
TagHelpers\AutoLinkerTagHelper.cs (1)
17
output.
Content
.AppendHtml(Regex.Replace(
TagHelpers\DefaultEncoderTagHelper.cs (1)
19
output.
Content
TagHelpers\DictionaryPrefixTestTagHelper.cs (1)
29
output.
Content
.SetHtmlContent(ulTag);
TagHelpers\NestedViewImportsTagHelper.cs (1)
13
output.
Content
.AppendHtml("nested-content");
TagHelpers\RootViewStartTagHelper.cs (1)
13
output.
Content
.AppendHtml("root-content");
TagHelpers\TagCloudViewComponentTagHelper.cs (1)
64
output.
Content
.AppendHtml(writer.ToString());