4 instantiations of DocsContent
aspire (1)
Documentation\Docs\DocsIndexService.cs (1)
451
return new
DocsContent
Aspire.Cli.Tests (3)
Commands\DocsCommandTests.cs (2)
158
var document = new
DocsContent
261
["redis-integration"] =
new
()
Mcp\TestDocsIndexService.cs (1)
58
return ValueTask.FromResult<DocsContent?>(new
DocsContent
31 references to DocsContent
aspire (5)
Commands\DocsGetCommand.cs (1)
62
var
doc = await InteractionService.ShowStatusAsync(
Documentation\Docs\DocsIndexService.cs (2)
51
ValueTask<
DocsContent
?> GetDocumentAsync(string slug, string? section = null, CancellationToken cancellationToken = default);
416
public async ValueTask<
DocsContent
?> GetDocumentAsync(string slug, string? section = null, CancellationToken cancellationToken = default)
JsonSourceGenerationContext.cs (1)
49
[JsonSerializable(typeof(
DocsContent
))]
Mcp\Tools\GetDocTool.cs (1)
78
var
doc = await _docsIndexService.GetDocumentAsync(slug, section, cancellationToken).ConfigureAwait(false);
Aspire.Cli.Tests (26)
Commands\DocsCommandTests.cs (9)
158
var
document = new DocsContent
195
options.DocsIndexServiceFactory = _ => new TestDocsIndexService(new Dictionary<string,
DocsContent
>
255
private readonly IReadOnlyDictionary<string,
DocsContent
> _documents;
257
public TestDocsIndexService(IReadOnlyDictionary<string,
DocsContent
>? documents = null)
259
_documents = documents ?? new Dictionary<string,
DocsContent
>
301
public ValueTask<
DocsContent
?> GetDocumentAsync(string slug, string? section = null, CancellationToken cancellationToken = default)
303
if (_documents.TryGetValue(slug, out
var
document))
305
return ValueTask.FromResult<
DocsContent
?>(document);
308
return ValueTask.FromResult<
DocsContent
?>(null);
Mcp\Docs\DocsIndexServiceTests.cs (14)
336
var
doc = await service.GetDocumentAsync("redis-integration");
356
var
doc = await service.GetDocumentAsync("REDIS-INTEGRATION");
375
var
doc = await service.GetDocumentAsync("nonexistent-doc");
399
var
doc = await service.GetDocumentAsync("redis-integration", "Installation");
420
var
doc = await service.GetDocumentAsync("redis-integration", "Getting Started");
446
var
doc = await service.GetDocumentAsync("redis-integration");
474
var
doc = await service.GetDocumentAsync("certificate-configuration");
499
var
doc = await service.GetDocumentAsync("certificate-configuration");
635
var
document = await service.GetDocumentAsync("deploy-to-azure");
708
var
doc = await service.GetDocumentAsync(null!);
726
var
doc = await service.GetDocumentAsync("");
744
var
doc = await service.GetDocumentAsync(" ");
788
var
doc = await service.GetDocumentAsync("any-slug");
899
var
doc = await service.GetDocumentAsync("redis-integration", "NonExistentSection");
Mcp\TestDocsIndexService.cs (3)
49
public ValueTask<
DocsContent
?> GetDocumentAsync(string slug, string? section = null, CancellationToken cancellationToken = default)
54
return ValueTask.FromResult<
DocsContent
?>(null);
58
return ValueTask.FromResult<
DocsContent
?>(new DocsContent