Skip to content

test(example): 💍 wait for the load answers, not one main-queue turn - #47

Merged
ChenYilong merged 1 commit into
masterfrom
fix/flaky-load-policy-test
Dec 3, 2026
Merged

ChenYilong merged 1 commit into
masterfrom
fix/flaky-load-policy-test

Conversation

@ChenYilong

Copy link
Copy Markdown
Owner

Summary

Fixes the real failure in the recent iOS CI runs: CYLTagListEditingTests.testLoadPoliciesOrderTheCacheAndTheServer (Unit tests (example), run 46886461286) waited one main-queue turn with a 5 s timeout. On a slow macOS runner, only the cache answer had arrived by then.

  • The test now waits for the expected number of answers (expectedFulfillmentCount) with a 30 s timeout; an extra answer still fails it.
  • The shared waitForDelivery helper's timeout is 30 s.
  • Example tests only; no library change.

The other red runs had no code failure:

  • Run 46883401556: Unit tests (swift) never got a runner and was replaced in its queue.
  • The SwiftPM failure on 82a42dfc came from the old revision pin; master's SwiftPM job passes with from: "1.100.1".

Verified here: the file parses (swiftc -parse). The test itself runs only on macOS, so this PR's Unit tests (example) job is the check.


Generated by Claude Code

testLoadPoliciesOrderTheCacheAndTheServer waited one main-queue turn
for 5 s and failed on a slow macOS runner (258 tests in 245 s): only
the cache answer had arrived. It now waits for the expected number of
answers with a 30 s timeout, and an extra answer still fails the test.

By @ChenYilong <luohanchenyilong@163.com>

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017y7XP2P2UnTvzHG1KZL67A

Copy link
Copy Markdown
Owner Author

SwiftPM build is red, but not because of this PR. This PR only changes one example test (CYLTagListEditingTests), and every required check is green, including Unit tests (example), which this PR fixes.

The failure: error: Unable to resolve module dependency: 'CYLUtilsObjC' (in target 'CYLAnimatedItemSwift' from project 'CYLTabBarController'). It comes from the tab bar mirror CYLTabBarController-Swift 1.100.1 (d5c62923). It reproduced on the re-run (attempt 2), and the same error appeared on 82a42dfc, while master 917c89ae passed with the same mirror commit.

Root cause: in that mirror, target CYLAnimatedItemSwift (Package.swift lines 57–62) declares no dependencies. Its file CYLTabBarItemAnimation/Swift/CYLTabBarItemAnimationPlayableView.swift still has #if canImport(CYLUtilsKit) / import CYLUtilsKit, and CYLUtilsKit needs CYLUtilsObjC. Whether canImport is true depends on build order, so Xcode's explicit-module build sometimes can't resolve the undeclared CYLUtilsObjC.

Proposed fix (in CYLTabBarController, then a new mirror tag): either remove that canImport / import from CYLAnimatedItemSwift, or make the dependency explicit in Package.swift. I've sent this to the CYLTabBarController session. Once a fixed mirror tag exists, this repository moves its from: requirement to it.


Generated by Claude Code

@ChenYilong
ChenYilong merged commit aae5ea2 into master Dec 3, 2026
27 of 29 checks passed
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.

2 participants