Skip to content

Fix flaky tests#264

Merged
nowsprinting merged 2 commits intomasterfrom
chore/fix_flaky_tests
Oct 24, 2025
Merged

Fix flaky tests#264
nowsprinting merged 2 commits intomasterfrom
chore/fix_flaky_tests

Conversation

@nowsprinting
Copy link
Copy Markdown
Owner

No description provided.

@github-actions github-actions bot added the chore label Oct 1, 2025
@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@nowsprinting nowsprinting marked this pull request as ready for review October 24, 2025 22:08
Copilot AI review requested due to automatic review settings October 24, 2025 22:08
Copy link
Copy Markdown
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 PR fixes flaky tests by improving test stability and consistency. The changes address timing-related test failures and inconsistent initial values that could cause intermittent test failures.

Key changes:

  • Introduces an explicit initial value for LastDragPosition to prevent reliance on default struct values
  • Extracts magic number (10) into a named constant RandomTestRepeatCount for better maintainability
  • Adjusts timing assertion threshold from 49ms to 17ms to reduce false failures

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
SpyOnDragHandler.cs Adds explicit initial value for LastDragPosition to prevent test flakiness from default value comparisons
UguiSwipeOperatorTest.cs Refactors repeat count to constant and updates assertions to use explicit initial value
UguiScrollWheelOperatorTest.cs Replaces hardcoded repeat count with named constant
UguiDragAndDropOperatorTest.cs Adds repeat attribute and updates assertion to use explicit initial value
UguiDoubleClickOperatorTest.cs Loosens timing assertion threshold to reduce flaky failures

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link
Copy Markdown

Code Metrics Report

master (33ba08e) #264 (8376475) +/-
Coverage 85.0% 85.0% 0.0%
Code to Test Ratio 1:1.3 1:1.3 +0.0
Test Execution Time 10m41s 13m19s +2m38s
Details
  |                     | master (33ba08e) | #264 (8376475) |  +/-   |
  |---------------------|------------------|----------------|--------|
  | Coverage            |            85.0% |          85.0% |   0.0% |
  |   Files             |               67 |             67 |      0 |
  |   Lines             |             2258 |           2258 |      0 |
  |   Covered           |             1921 |           1921 |      0 |
+ | Code to Test Ratio  |            1:1.3 |          1:1.3 |   +0.0 |
  |   Code              |             4162 |           4162 |      0 |
+ |   Test              |             5723 |           5728 |     +5 |
- | Test Execution Time |           10m41s |         13m19s | +2m38s |

Reported by octocov

@nowsprinting nowsprinting merged commit e7c4518 into master Oct 24, 2025
14 checks passed
@nowsprinting nowsprinting deleted the chore/fix_flaky_tests branch October 24, 2025 22:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants