Warn on a helper-derived property id; reject DSN credentials - #18
Merged
Conversation
- forAll() derives the property id from its caller; called from a helper (not the test method) that id names the helper, so every test using the helper shares one corpus entry and overwrites the others' counterexample. It now warns on stderr, like a closure-derived id already did; ->id() silences it. The signal is a mismatch between the derived method and TestCase::name(). - RedisDsn rejects a DSN carrying userinfo instead of dropping it (the connection would otherwise go without AUTH); the error never echoes the DSN. Fixes #14 Fixes #15
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Resolving runs once per property; a Redis suite otherwise built a client and opened a connection per property. Keeps corpus resolution at parity with property-testing-testo 0.6.2.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #14, #15.
#14 helper-derived id (MEDIUM)
forAll()derives the property id from its caller. Called from a helper method (not the test method), that id names the helper — so every test routing through the helper shares one corpus entry and prunes the others' regression, with no warning (the id looks stable, it's just the wrong method). It now warns on stderr, the way a closure-derived id already did;->id()silences it. The signal is a mismatch between the backtrace-derived method andTestCase::name()(allowed inpsalm.xmlalongside the adapter's other PHPUnit-internal boundary points).#15 DSN credentials (shared with testo#19)
redis://user:pass@hosthad its userinfo silently dropped (connection without AUTH). Now rejected; the error never echoes the DSN.Verification
composer buildgreen — 99 tests, 2985 assertions, psalm 100%.= falsedefault, whichforAll()always overrides explicitly.Sister issue
DSN credentials in the Testo adapter: rasuvaeff/property-testing-testo#19.