Skip to content

[Testing] Fix for flaky UITests in CI - 5#33259

Merged
PureWeen merged 3 commits intodotnet:mainfrom
TamilarasanSF4853:origin/fix-flaky-tests-6
Dec 26, 2025
Merged

[Testing] Fix for flaky UITests in CI - 5#33259
PureWeen merged 3 commits intodotnet:mainfrom
TamilarasanSF4853:origin/fix-flaky-tests-6

Conversation

@TamilarasanSF4853
Copy link
Contributor

This pull request makes minor adjustments to the shadow feature test UI and test logic. The main change is the removal of the numeric keyboard from several entry fields in the shadow feature test page, and a small improvement to the shadow color test to clear the color entry before entering a new value.

UI adjustments in shadow feature page:

  • Removed the Keyboard="Numeric" property from the OffsetXEntry, OffsetYEntry, RadiusEntry, and OpacityEntry input fields in ShadowFeaturePage.xaml, so these fields will now use the default keyboard instead of the numeric keyboard.

Test improvements:

  • Updated the Shadow_SetColor test to clear the ColorEntry field before entering a new color value, ensuring the test input is not affected by any previous value.

@dotnet-policy-service dotnet-policy-service bot added the community ✨ Community Contribution label Dec 22, 2025
@dotnet-policy-service
Copy link
Contributor

Hey there @@TamilarasanSF4853! Thank you so much for your PR! Someone from the team will get assigned to your PR shortly and we'll get it reviewed.

@dotnet-policy-service dotnet-policy-service bot added the partner/syncfusion Issues / PR's with Syncfusion collaboration label Dec 22, 2025
@Ahamed-Ali Ahamed-Ali added the area-testing Unit tests, device tests label Dec 22, 2025
@sheiksyedm sheiksyedm marked this pull request as ready for review December 22, 2025 16:12
Copilot AI review requested due to automatic review settings December 22, 2025 16:12
Copy link
Contributor

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.

Pull request overview

This pull request aims to fix flaky UI tests for the Shadow feature by making two key changes: removing the numeric keyboard specification from Entry fields in the test UI page, and adding a ClearText call before entering color values in the test logic.

Key Changes:

  • Removal of Keyboard="Numeric" from 4 Entry fields (OffsetX, OffsetY, Radius, Opacity)
  • Addition of App.ClearText("ColorEntry") before text entry in Shadow_SetColor test
  • Updated iOS snapshot image for the Shadow_SetVisibilityToFalse test

Reviewed changes

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

File Description
ShadowFeaturePage.xaml Removed Keyboard="Numeric" from 4 Entry fields that accept numeric shadow property values
ShadowFeatureTests.cs Added ClearText("ColorEntry") call before entering text to ensure clean test state
Shadow_SetVisibilityToFalse_VerifyScreenshot.png New snapshot image added for iOS test baseline

Comment on lines +75 to +81
<controls:UITestEntry x:Name="OffsetXEntry" AutomationId="OffsetXEntry" IsCursorVisible="False" Text="{Binding OffsetX}" TextChanged="OnOffsetXChanged" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Offset X" />
<Label AutomationId="OffsetYValue" Text="{Binding OffsetY, StringFormat='OffsetY: {0}'}" FontSize="15" />
<controls:UITestEntry x:Name="OffsetYEntry" AutomationId="OffsetYEntry" IsCursorVisible="False" Text="{Binding OffsetY}" TextChanged="OnOffsetYChanged" Keyboard="Numeric" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Offset Y" />
<controls:UITestEntry x:Name="OffsetYEntry" AutomationId="OffsetYEntry" IsCursorVisible="False" Text="{Binding OffsetY}" TextChanged="OnOffsetYChanged" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Offset Y" />
<Label AutomationId="RadiusValue" Text="{Binding Radius, StringFormat='Radius: {0}'}" FontSize="15" />
<controls:UITestEntry x:Name="RadiusEntry" AutomationId="RadiusEntry" IsCursorVisible="False" Text="{Binding Radius}" TextChanged="OnRadiusChanged" Keyboard="Numeric" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Radius" />
<controls:UITestEntry x:Name="RadiusEntry" AutomationId="RadiusEntry" IsCursorVisible="False" Text="{Binding Radius}" TextChanged="OnRadiusChanged" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Radius" />
<Label AutomationId="OpacityValue" Text="{Binding Opacity, StringFormat='Opacity: {0}'}" FontSize="15" />
<controls:UITestEntry x:Name="OpacityEntry" AutomationId="OpacityEntry" IsCursorVisible="False" Text="{Binding Opacity}" TextChanged="OnOpacityChanged" Keyboard="Numeric" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Opacity" />
<controls:UITestEntry x:Name="OpacityEntry" AutomationId="OpacityEntry" IsCursorVisible="False" Text="{Binding Opacity}" TextChanged="OnOpacityChanged" HorizontalOptions="Start" WidthRequest="100" Placeholder="Shadow Opacity" />
Copy link

Copilot AI Dec 22, 2025

Choose a reason for hiding this comment

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

Removing the numeric keyboard from these Entry fields may reduce usability for end users. These fields expect numeric values (OffsetX, OffsetY, Radius, Opacity), so the numeric keyboard provides a better user experience by showing only numeric keys.

If the numeric keyboard is causing UI test flakiness, consider investigating why that's happening rather than removing it. The flakiness could be due to:

  • Appium/UI test framework issues with specific keyboard types
  • Timing issues with keyboard animations
  • Platform-specific keyboard behavior

If removing the numeric keyboard is the intended fix for test stability, please document this decision in the PR description explaining why this approach was chosen over addressing the root cause of the flakiness.

Copilot uses AI. Check for mistakes.
Copy link
Member

@PureWeen PureWeen left a comment

Choose a reason for hiding this comment

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

@TamilarasanSF4853
Copy link
Contributor Author

@PureWeen PureWeen merged commit 1f06a2b into dotnet:main Dec 26, 2025
153 of 161 checks passed
StephaneDelcroix pushed a commit that referenced this pull request Jan 5, 2026
This pull request makes minor adjustments to the shadow feature test UI
and test logic. The main change is the removal of the numeric keyboard
from several entry fields in the shadow feature test page, and a small
improvement to the shadow color test to clear the color entry before
entering a new value.

UI adjustments in shadow feature page:

* Removed the `Keyboard="Numeric"` property from the `OffsetXEntry`,
`OffsetYEntry`, `RadiusEntry`, and `OpacityEntry` input fields in
`ShadowFeaturePage.xaml`, so these fields will now use the default
keyboard instead of the numeric keyboard.

Test improvements:

* Updated the `Shadow_SetColor` test to clear the `ColorEntry` field
before entering a new color value, ensuring the test input is not
affected by any previous value.
@github-actions github-actions bot locked and limited conversation to collaborators Jan 26, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-testing Unit tests, device tests community ✨ Community Contribution partner/syncfusion Issues / PR's with Syncfusion collaboration

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants