Skip to content
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

Add unit tests for TableLayoutPanelDesigner #13028

Conversation

MelonWang1
Copy link
Contributor

@MelonWang1 MelonWang1 commented Feb 26, 2025

Related #10773

Proposed changes

  • Add unit test TableLayoutPanelDesignerTests.cs for some public properties and method of the TableLayoutPanelDesigner.
Microsoft Reviewers: Open in CodeFlow

@MelonWang1 MelonWang1 requested a review from a team as a code owner February 26, 2025 02:41
@MelonWang1 MelonWang1 changed the title Add unit tests for table layout panel designer Add unit tests for TableLayoutPanelDesigner Feb 26, 2025
Copy link

codecov bot commented Feb 26, 2025

Codecov Report

Attention: Patch coverage is 95.45455% with 9 lines in your changes missing coverage. Please review.

Project coverage is 76.15066%. Comparing base (8ef1b9c) to head (6c4e9cf).
Report is 90 commits behind head on main.

Additional details and impacted files
@@                 Coverage Diff                 @@
##                main      #13028         +/-   ##
===================================================
+ Coverage   75.97321%   76.15066%   +0.17745%     
===================================================
  Files           3265        3276         +11     
  Lines         643286      644001        +715     
  Branches       47431       47461         +30     
===================================================
+ Hits          488725      490411       +1686     
+ Misses        150991      150031        -960     
+ Partials        3570        3559         -11     
Flag Coverage Δ
Debug 76.15066% <95.45455%> (+0.17745%) ⬆️
integration 18.04847% <ø> (+0.03630%) ⬆️
production 50.22482% <ø> (+0.35914%) ⬆️
test 96.94962% <95.45455%> (-0.00358%) ⬇️
unit 47.62950% <ø> (+0.30449%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ricardobossan ricardobossan added the waiting-author-feedback The team requires more information from the author label Feb 27, 2025
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

PR Overview

This PR adds unit tests for the TableLayoutPanelDesigner component to verify the behavior of its public properties, methods, and its nested DesignerTableLayoutControlCollection, and enables nullability in the test file.

  • Added tests for RowCount, ColumnCount, and Verbs properties.
  • Added tests covering behaviors of the DesignerTableLayoutControlCollection (e.g., Add, AddRange, CopyTo, GetEnumerator, and index-related methods).

Reviewed Changes

File Description
src/System.Windows.Forms.Design/tests/UnitTests/System/Windows/Forms/Design/TableLayoutPanelDesignerTests.cs New and updated tests for TableLayoutPanelDesigner functionalities

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

@MelonWang1 MelonWang1 removed the waiting-author-feedback The team requires more information from the author label Feb 28, 2025
ricardobossan
ricardobossan previously approved these changes Feb 28, 2025
Copy link
Member

@ricardobossan ricardobossan left a comment

Choose a reason for hiding this comment

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

Thank you!

@Tanya-Solyanik Tanya-Solyanik added the waiting-author-feedback The team requires more information from the author label Mar 5, 2025
@MelonWang1 MelonWang1 removed the waiting-author-feedback The team requires more information from the author label Mar 6, 2025
Copy link
Member

@ricardobossan ricardobossan left a comment

Choose a reason for hiding this comment

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

Thank you!

Copy link
Member

@Tanya-Solyanik Tanya-Solyanik left a comment

Choose a reason for hiding this comment

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

Thank you!

@Tanya-Solyanik Tanya-Solyanik merged commit 5fb62d5 into dotnet:main Mar 6, 2025
8 checks passed
@dotnet-policy-service dotnet-policy-service bot added this to the 10.0 Preview3 milestone Mar 6, 2025
@MelonWang1 MelonWang1 deleted the Add_unit_tests_for_TableLayoutPanelDesigner branch March 7, 2025 01:18
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.

3 participants