[Testing] Feature matrix UITest Cases for Border Control#29746
Conversation
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Pull Request Overview
This PR introduces a new Border feature matrix in the Maui.Controls.Sample app, including a view model, two pages for configuring and displaying border properties, and a new navigation entry.
- Adds
BorderViewModelwith bindable border properties and content selectors - Implements
BorderControlMainPageandOptionsPagefor live configuration of stroke, padding, shadow, etc. - Registers the feature in the gallery and adds initial tests in the HostApp
Reviewed Changes
Copilot reviewed 37 out of 37 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/Controls/tests/TestCases.HostApp/FeatureMatrix/Border/BorderViewModel.cs | Implements all border properties and content update methods |
| src/Controls/tests/TestCases.HostApp/FeatureMatrix/Border/BorderOptionsPage.xaml(.cs) | UI for editing border settings and event handlers |
| src/Controls/tests/TestCases.HostApp/FeatureMatrix/Border/BorderControlsPage.xaml(.cs) | Main page with Border bound to the view model and navigation logic |
| src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs | Adds the “Border Feature Matrix” entry to the app navigation |
Comments suppressed due to low confidence (3)
src/Controls/tests/TestCases.HostApp/CoreViews/CorePageView.cs:81
- You've registered the new Border feature matrix in the HostApp, but there’s no corresponding shared automated test in
TestCases.Shared.Tests. Please add a test case to cover the new UI flow and ensure it runs against the HostApp.
new GalleryPageFactory(() => new BorderControlPage(), "Border Feature Matrix"),
src/Controls/tests/TestCases.HostApp/FeatureMatrix/Border/BorderOptionsPage.xaml.cs:7
- [nitpick] The file is named
BorderOptionsPage.xaml.csbut the class isOptionsPage. Consider renaming the class toBorderOptionsPage(or vice versa) to keep names consistent and clear.
public partial class OptionsPage : ContentPage
src/Controls/tests/TestCases.HostApp/FeatureMatrix/Border/BorderOptionsPage.xaml.cs:46
- Assigning a
Colorto aBrushproperty may not work. Wrap the selected color in aSolidColorBrush, for example:_viewModel.Stroke = new SolidColorBrush(button.BackgroundColor);.
_viewModel.Stroke = button.BackgroundColor;
|
|
||
| private void OnSetGridContentClicked(object sender, EventArgs e) | ||
| { | ||
| var grid = new Grid |
There was a problem hiding this comment.
The grid is instantiated but never applied to the Border or ViewModel. You should assign it (e.g., _viewModel.ContentView = grid;) so the UI actually updates when the button is clicked.
There was a problem hiding this comment.
Removed the event handler and updated the corresponding changes.
|
|
||
| private void OnSetStackContentClicked(object sender, EventArgs e) | ||
| { | ||
| var stack = new VerticalStackLayout |
There was a problem hiding this comment.
The stack layout is created but not used. Consider assigning it to the ViewModel (e.g., _viewModel.ContentView = stack;) or directly to the Border so it appears in the UI.
There was a problem hiding this comment.
Removed the event handler and updated the corresponding changes.
Hi @jsuarezruiz, I have attached the required Snapshots |
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
f5a279d to
c33253a
Compare
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
jsuarezruiz
left a comment
There was a problem hiding this comment.
I think is not related with the PR, but the test NullPointerExceptionOnFastLabelTextColorChange is failing on iOS and Cataluyst because a crash.
The app was expected to be running still, investigate as possible crash
24dd756 to
0423cbb
Compare
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
Hi @jsuarezruiz, |
42ca2bd to
b5a6090
Compare
|
/azp run |
|
Azure Pipelines successfully started running 3 pipeline(s). |
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
/rebase |
|
/azp run MAUI-UITests-public |
|
Azure Pipelines successfully started running 1 pipeline(s). |
* harish_feature_matrix_border * Update BorderFeatureTests.cs * Updated BorderFeatureTest.cs * Update BorderFeatureTests.cs * Added Shapes for Border Control * Updated the TestCases * Added Snapshots * Updated the SnapShots * Added Fails to the Testcase * Update BorderFeatureTests.cs * Update BorderFeatureTests.cs * Updated the Windows Snapshots
* harish_feature_matrix_border * Update BorderFeatureTests.cs * Updated BorderFeatureTest.cs * Update BorderFeatureTests.cs * Added Shapes for Border Control * Updated the TestCases * Added Snapshots * Updated the SnapShots * Added Fails to the Testcase * Update BorderFeatureTests.cs * Update BorderFeatureTests.cs * Updated the Windows Snapshots
* harish_feature_matrix_border * Update BorderFeatureTests.cs * Updated BorderFeatureTest.cs * Update BorderFeatureTests.cs * Added Shapes for Border Control * Updated the TestCases * Added Snapshots * Updated the SnapShots * Added Fails to the Testcase * Update BorderFeatureTests.cs * Update BorderFeatureTests.cs * Updated the Windows Snapshots
* harish_feature_matrix_border * Update BorderFeatureTests.cs * Updated BorderFeatureTest.cs * Update BorderFeatureTests.cs * Added Shapes for Border Control * Updated the TestCases * Added Snapshots * Updated the SnapShots * Added Fails to the Testcase * Update BorderFeatureTests.cs * Update BorderFeatureTests.cs * Updated the Windows Snapshots
* harish_feature_matrix_border * Update BorderFeatureTests.cs * Updated BorderFeatureTest.cs * Update BorderFeatureTests.cs * Added Shapes for Border Control * Updated the TestCases * Added Snapshots * Updated the SnapShots * Added Fails to the Testcase * Update BorderFeatureTests.cs * Update BorderFeatureTests.cs * Updated the Windows Snapshots





Description
This pull request introduces a new feature matrix for the Border control in the Maui.Controls.Sample project. It includes updates to the UI, view model, and test cases to support the feature matrix. The feature matrix enables detailed testing of properties like Stroke, StrokeThickness, StrokeShape, Shadow, and dynamic content.
FeatureMatrix : Border Control
Added a new entry for
BorderControlPagein the gallery navigation to integrate the new feature into the application.Created
BorderControlsPage.xamlto define the layout and bindings for the main border control page. This includes aBorderelement with customizable properties such as stroke, padding, shadow, and content.Added
BorderOptionsPage.xamlto provide a UI for configuring border properties like stroke thickness, dash array, shadow, and content options.Implemented
BorderControlPageandBorderControlMainPageclasses to manage navigation and bind the view model to the main page. Added event handlers for setting grid and stack layouts as contentDeveloped
OptionsPageclass to handle user input for border configuration, including stroke color, shape, shadow, and line cap/line join options. Added validation and event handling for user interactionsAdded tests in
BorderFeatureMatrixTests.csto validate default values, property updates, and visual rendering of Border control properties across platforms.Identified Issue:
Screen.Recording.2025-05-30.at.4.41.00.PM.mov