1 write to Sections
aspire (1)
Mcp\Docs\LlmsTxtParser.cs (1)
207Sections = sections
34 references to Sections
aspire (4)
Mcp\Docs\DocsIndexService.cs (4)
240var matchedSection = doc.Source.Sections.FirstOrDefault(s => 256Sections = [.. doc.Source.Sections.Select(static s => s.Heading)] 288matchedSection = doc.Source.Sections[i].Heading; 443.. source.Sections.Select(static s => new IndexedSection(s))
Aspire.Cli.Tests (30)
Mcp\Docs\LlmsTxtParserTests.cs (30)
107Assert.Equal(3, doc.Sections.Count); 109Assert.Equal("Section One", doc.Sections[0].Heading); 110Assert.Equal(2, doc.Sections[0].Level); 112Assert.Equal("Section Two", doc.Sections[1].Heading); 113Assert.Equal(2, doc.Sections[1].Level); 115Assert.Equal("Subsection", doc.Sections[2].Heading); 116Assert.Equal(3, doc.Sections[2].Level); 138var parentSection = doc.Sections.First(s => s.Heading == "Parent Section"); 356Assert.Equal(2, overview.Sections.Count); 357Assert.Equal("Why use Aspire?", overview.Sections[0].Heading); 358Assert.Equal("Getting started", overview.Sections[1].Heading); 365Assert.Single(serviceDefaults.Sections); 366Assert.Equal("Configuration", serviceDefaults.Sections[0].Heading); 470var h2Sections = doc.Sections.Where(s => s.Level == 2).Select(s => s.Heading).ToList(); 474var h3Sections = doc.Sections.Where(s => s.Level == 3).Select(s => s.Heading).ToList(); 502Assert.Single(doc.Sections); 503Assert.Equal("Real Section", doc.Sections[0].Heading); 504Assert.Equal(2, doc.Sections[0].Level); 517Assert.Single(doc.Sections); 518Assert.Equal("Getting Started", doc.Sections[0].Heading); 569Assert.True(certificatesDoc.Sections.Count > 0, "Certificate doc should have sections"); 572var h2Sections = certificatesDoc.Sections.Where(s => s.Level == 2).Select(s => s.Heading).ToList(); 579var h3Sections = certificatesDoc.Sections.Where(s => s.Level == 3).ToList(); 589Assert.True(appHostConfigDoc.Sections.Count > 0, "AppHost config doc should have sections"); 591var h2Sections = appHostConfigDoc.Sections.Where(s => s.Level == 2).Select(s => s.Heading).ToList(); 605Assert.True(dockerComposeDoc.Sections.Count > 0, "Docker Compose doc should have sections"); 607var h2Sections = dockerComposeDoc.Sections.Where(s => s.Level == 2).Select(s => s.Heading).ToList(); 621Assert.True(eventingDoc.Sections.Count > 0, "Eventing doc should have sections"); 623var h2Sections = eventingDoc.Sections.Where(s => s.Level == 2).Select(s => s.Heading).ToList(); 630var h3Sections = eventingDoc.Sections.Where(s => s.Level == 3).Select(s => s.Heading).ToList();