Conversation
API Changesgithub.com/rekby/fixenvincompatible changes(*EnvT).CacheResult: removed summaryBase version: v0.7.1 (latest) |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| // T - return t object of current test/benchmark. | ||
| T() T | ||
|
|
||
| // CacheResult add result of call f to cache and return same result for all | ||
| // calls for the same function and cache options within cache scope | ||
| CacheResult(f FixtureFunction, options ...CacheOptions) interface{} | ||
| cacheResult(f fixtureFunction, options ...CacheOptions) interface{} |
There was a problem hiding this comment.
Exported Env interface uses unexported parameter type
The public Env interface now exposes cacheResult(f fixtureFunction, ...). Because fixtureFunction is unexported, code outside this package cannot mention that type in a method signature and therefore can no longer implement Env. The comment above the interface still encourages users to create their own environments, so this unintentionally seals the interface and breaks external implementations that previously satisfied it. Consider keeping the method signature in terms of an exported type or providing a public wrapper so third‑party envs remain possible.
Useful? React with 👍 / 👎.
Summary
CacheResultGenericResultvalues instead of legacy wrappersTesting
https://chatgpt.com/codex/tasks/task_e_690153716878832585d1664da96bba4b