Skip to content

String Split: fix cross-platform newline split; retarget net10.0 - #2108

Closed
vladimir-pecanac-main wants to merge 1 commit into
CodeMazeBlog:mainfrom
vladimir-pecanac-main:seo/86541-string-split
Closed

String Split: fix cross-platform newline split; retarget net10.0#2108
vladimir-pecanac-main wants to merge 1 commit into
CodeMazeBlog:mainfrom
vladimir-pecanac-main:seo/86541-string-split

Conversation

@vladimir-pecanac-main

Copy link
Copy Markdown
Collaborator

Retargets the SplitString sample to net10.0 and bumps its test packages to current stable (MSTest 4.3.3, Microsoft.NET.Test.Sdk 18.9.0, coverlet 10.0.1).

Fixes the new-lines example, which split a \n-only input on Environment.NewLine (\r\n on Windows) yet asserted five elements — so the test returned one element and failed on Windows. Normalising with ReplaceLineEndings() before the split makes it deterministic on any OS. All 7 tests pass on net10.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant