Skip to content

Cleanup, Tests | MultipartIdentifier#3891

Merged
paulmedynski merged 21 commits intodotnet:mainfrom
edwardneal:cleanup/multipartidentifier
Mar 9, 2026
Merged

Cleanup, Tests | MultipartIdentifier#3891
paulmedynski merged 21 commits intodotnet:mainfrom
edwardneal:cleanup/multipartidentifier

Conversation

@edwardneal
Copy link
Contributor

Description

This work performs a small cleanup of the MultipartIdentifier type, and moves its test into the UnitTests project. That simplifies some of the tech debt identified in #3890, since we can use InternalsVisibleTo to access the type directly rather than manually include the source file.

This can be reviewed commit-by-commit - I don't expect any behavioural changes. There's existing test coverage, and this passes, but everything can be verified statically. These changes essentially remove parameters which are always constant, but which were passed as a result of the MultipartIdentifier type being originally used for providers other than SqlClient.

Issues

None, but dovetails with #3890 - @benrr101 for awareness.

Testing

Existing automatic tests cover this.

These were always passed with the same, constant, value.
This tested a case which would never occur.
Also remove now-unnecessary test case.
Also remove a now-unnecessary test case.
Remove unnecessary IsWhitespace method.
Replace always-true runtime checks against constant values with debug assertions.
This tested the exception thrown when limit is zero. This is always either 3 or 4.
…ional inclusion of MultipartIdentifier from FunctionalTests
@edwardneal edwardneal requested a review from a team as a code owner January 14, 2026 06:57
@github-project-automation github-project-automation bot moved this to To triage in SqlClient Board Jan 14, 2026
@paulmedynski paulmedynski moved this from To triage to In review in SqlClient Board Jan 14, 2026
@paulmedynski paulmedynski added the Area\Tests Issues that are targeted to tests or test projects label Jan 14, 2026
@paulmedynski
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

Copy link
Contributor

@paulmedynski paulmedynski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another good move of some true unit tests, and valuable cleanup along the way. A few suggestions to improve the cleanup even more.

@github-project-automation github-project-automation bot moved this from In review to In progress in SqlClient Board Jan 14, 2026
Eliminates some ambiguity between "name" and "identifier", "identifier part" or "property name".
@edwardneal
Copy link
Contributor Author

Thanks @paulmedynski - I've just replied to the first round of review comments.

@github-actions
Copy link

This pull request has been marked as stale due to inactivity for more than 30 days.

If you would like to keep this pull request open, please provide an update or respond to any comments. Otherwise, it will be closed automatically in 7 days.

@github-actions github-actions bot added the Stale The Issue or PR has become stale and will be automatically closed shortly if no activity occurs. label Feb 14, 2026
@paulmedynski
Copy link
Contributor

@Wraith2 - Yes, please open a PR with your changes!

@paulmedynski paulmedynski merged commit 326a242 into dotnet:main Mar 9, 2026
296 checks passed
@github-project-automation github-project-automation bot moved this from In progress to Done in SqlClient Board Mar 9, 2026
@edwardneal edwardneal deleted the cleanup/multipartidentifier branch March 9, 2026 19:32
This was referenced Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area\Tests Issues that are targeted to tests or test projects

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants