Skip to content

test: fix random-order failures in Config, Honeypot, and Test#10168

Open
memleakd wants to merge 2 commits intocodeigniter4:developfrom
memleakd:refactor/random-tests-small-components
Open

test: fix random-order failures in Config, Honeypot, and Test#10168
memleakd wants to merge 2 commits intocodeigniter4:developfrom
memleakd:refactor/random-tests-small-components

Conversation

@memleakd
Copy link
Copy Markdown
Contributor

@memleakd memleakd commented May 6, 2026

Description

Related to #9968

This fixes several test-order dependencies found while working on random test execution support.

This updates tests in the Config, Honeypot, and Test components so they no longer depend on state left behind by earlier tests:

  • reset mutable static fixture state in ReflectionHelperTest
  • reset shared services/config factory state in HoneypotTest
  • avoid short-name factory alias pollution in FactoriesTest
  • clear loose.env overrides between BaseConfigTest methods
  • make FeatureTestTraitTest::testAutoRoutingLegacy() configure the actual route collection it uses

Verified locally:

  • random-order smoke runs for Config, Honeypot, and Test

Checklist:

  • Securely signed commits
  • Component(s) with PHPDoc blocks, only if necessary or adds value (without duplication)
  • Unit testing, with >80% coverage
  • User guide updated
  • Conforms to style guide

@github-actions github-actions Bot added the testing Pull requests that changes tests only label May 6, 2026
Signed-off-by: memleakd <121398829+memleakd@users.noreply.github.com>
@memleakd memleakd force-pushed the refactor/random-tests-small-components branch from 2deec0c to 0769f84 Compare May 6, 2026 22:27
Signed-off-by: memleakd <121398829+memleakd@users.noreply.github.com>
@github-actions github-actions Bot removed the testing Pull requests that changes tests only label May 6, 2026
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