mirror of
https://github.com/hwchase17/langchain.git
synced 2026-07-12 19:31:24 +00:00
Codex integration tests need to be skipped in CI whenever VCR is not in playback mode, but the setup-time skip ran too late: `pytest-recording` could already try to open a cassette and hit the missing on-disk OAuth token first. Moving the skip to collection time marks the matching Codex tests before cassette setup while keeping the existing VCR-token fake for playback runs. ## Changes - Add a `pytest_collection_modifyitems` hook that marks Codex chat-model integration tests as skipped in CI unless VCR is replaying existing cassettes. - Scope collection-time matching to the local chat-model integration-test directory so same-named modules collected elsewhere are not skipped accidentally. - Keep the OAuth-token fake path active for VCR playback by preserving `_fake_codex_oauth_token` behavior when `record_mode` is `none`.