You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit bcb6cc1
Browse filesBrowse the repository at this point in the historyBrowse files
Numeric format strings: retarget net10.0, add section separators, composite formatting and TryFormat (#2171)
- Retarget both projects from net8.0 to net10.0.
- Lift test packages: Microsoft.NET.Test.Sdk 18.9.0, xunit 2.9.3,
xunit.runner.visualstudio 4.0.0, coverlet.collector 10.0.1.
- CustomFormatStrings: add Accounting, BlankZero and EmptyThirdSection so the
semicolon section separator the article now teaches is runnable, including the
counter-intuitive case where an empty third section is ignored.
- StandardFormatStrings: add FixedPointPrecisionDecimal, Aligned,
AlignedInterpolated and TryFormatFixedPoint.
- Tests pin the rounding difference between double and decimal under "F2", the
composite format item's alignment component, and both TryFormat paths
(big enough buffer and too small a buffer).
- Tidy: StandardFormatsStrings.cs renamed to StandardFormatStrings.cs (and its
test file likewise) to match the class name, and CustomFormatStringsTests
moved to the same namespace as the rest of the test project.
Copy file name to clipboardExpand all lines: strings-csharp/StandardAndCustomFormatStrings/StandardAndCustomFormatStrings/StandardAndCustomFormatStrings.csproj
Copy file name to clipboardExpand all lines: strings-csharp/StandardAndCustomFormatStrings/StandardAndCustomFormatStringsTests/CustomFormatStringsTests.cs
Copy file name to clipboardExpand all lines: strings-csharp/StandardAndCustomFormatStrings/StandardAndCustomFormatStringsTests/StandardAndCustomFormatStringsTests.csproj
Copy file name to clipboardExpand all lines: strings-csharp/StandardAndCustomFormatStrings/StandardAndCustomFormatStringsTests/StandardFormatStringsTests.cs
+59-1Lines changed: 59 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -64,4 +64,62 @@ public void GivenANumber_WhenPercentage_ReturnsPercentage(double input, string e
0 commit comments