-
Notifications
You must be signed in to change notification settings - Fork 997
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 FocusableLabel #12773
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #12773 +/- ##
===================================================
- Coverage 76.18076% 76.13455% -0.04622%
===================================================
Files 3193 3233 +40
Lines 640306 642125 +1819
Branches 47237 47266 +29
===================================================
+ Hits 487790 488879 +1089
- Misses 148983 149699 +716
- Partials 3533 3547 +14
Flags with carried forward coverage won't be shown. Click here to find out more. |
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All LGTM!
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
New review added comments to be addressed
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Outdated
Show resolved
Hide resolved
src/System.Windows.Forms/tests/UnitTests/System/Windows/Forms/FocusableLabelTests.cs
Show resolved
Hide resolved
|
||
private class SubFocusableLabel : FocusableLabel | ||
{ | ||
public CreateParams? CreateParams => base.CreateParams; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As suggested in the failing checks:
src\System.Windows.Forms\tests\UnitTests\System\Windows\Forms\FocusableLabelTests.cs(37,30): error CS0114: (NETCORE_ENGINEERING_TELEMETRY=Build) 'FocusableLabelTests.SubFocusableLabel.CreateParams' hides inherited member 'FocusableLabel.CreateParams'. To make the current member override that implementation, add the override keyword. Otherwise add the new keyword.
Please add the new
keyword to line 37:
public new CreateParams? CreateParams => base.CreateParams;
.GetProperty("CreateParams", BindingFlags.NonPublic | BindingFlags.Instance)? | ||
.GetValue(control); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please indent lines 47 and 48.
related #10453
Proposed changes
Microsoft Reviewers: Open in CodeFlow