Skip to content

Remove extra newline from APIDiff TOC #49794

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,6 @@ public async Task RunAsync(CancellationToken cancellationToken)
_log.LogMessage($"Wrote '{filePath}'.");
}

tableOfContents.AppendLine();

string tableOfContentsFilePath = Path.Combine(_outputFolderPath, $"{_tableOfContentsTitle}.md");

if (_writeToDisk)
Expand Down
3 changes: 0 additions & 3 deletions test/Microsoft.DotNet.ApiDiff.Tests/Diff.Disk.Tests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ Lines preceded by a '+' are additions and a '-' indicates removal.

* [{DefaultAssemblyName}]({DefaultTableOfContentsTitle}_{DefaultAssemblyName}.md)


""";

private const string ExpectedEmptyTableOfContents = $"""
Expand All @@ -35,7 +34,6 @@ API listing follows standard diff formatting.
Lines preceded by a '+' are additions and a '-' indicates removal.



""";

private const string BeforeCode = """
Expand Down Expand Up @@ -239,7 +237,6 @@ Lines preceded by a '+' are additions and a '-' indicates removal.

* [Assembly1]({DefaultTableOfContentsTitle}_Assembly1.md)
* [Assembly2]({DefaultTableOfContentsTitle}_Assembly2.md)

";

using TempDirectory inputFolderPath = new();
Expand Down