Skip to content

tests: fix completion-order test with a single parser worker - #470

Open
bryango wants to merge 2 commits into
SaladDay:mainfrom
bryango:fix-parser-completion-order-test
Open

bryango wants to merge 2 commits into
SaladDay:mainfrom
bryango:fix-parser-completion-order-test

Conversation

@bryango

@bryango bryango commented Sep 19, 2026

Copy link
Copy Markdown
Contributor

一个小小的测试bug修复:test里面并行线程数的计算方法和实际代码中的不一致 导致在2-3线程的时候 这个测试会失败

解决办法:把线程数的计算方法抽出来 作为一个单独的函数,测试里面也调用这个函数就行了

The completion-order test only skipped on single-core systems, while the parser worker pool uses half of the available parallelism. On 2-3 core builders this leaves one worker, so completion order cannot differ from input order.

Factor the worker-count calculation into a helper and use the same calculation in the test guard.

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.

1 participant