test(anthropic): Stop mocking response iterator#5573
test(anthropic): Stop mocking response iterator#5573alexander-alderman-webb wants to merge 3 commits intomasterfrom
Conversation
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨
Bug Fixes 🐛
Documentation 📚
Internal Changes 🔧Openai Agents
Other
🤖 This preview updates automatically when you update the PR. |
Codecov Results 📊✅ 13 passed | Total: 13 | Pass Rate: 100% | Execution Time: 8.36s All tests are passing successfully. ✅ Patch coverage is 100.00%. Project has 13949 uncovered lines. Generated by Codecov Action |
| capture_events, | ||
| send_default_pii, | ||
| include_prompts, | ||
| server_side_event_chunks, |
There was a problem hiding this comment.
Missing pytest fixture 'server_side_event_chunks' will cause test failure
The test function test_streaming_create_message declares server_side_event_chunks as a fixture parameter, but this fixture is not defined anywhere in the codebase. The only definition of server_side_event_chunks is a plain generator function in tests/integrations/openai_agents/test_openai_agents.py, which is not a pytest fixture and is not accessible from the anthropic tests. This will cause pytest to raise a fixture 'server_side_event_chunks' not found error at test collection time.
Verification
Searched for 'server_side_event_chunks' definition across all files in tests/conftest.py, tests/integrations/conftest.py, and all *.py files. Found it only defined as a plain function (not a @pytest.fixture) in tests/integrations/openai_agents/test_openai_agents.py at line 1389. Verified the function is used as a parameter in test_streaming_create_message at line 224, which pytest interprets as a fixture request.
Also found at 1 additional location
tests/integrations/anthropic/test_anthropic.py:1316-1316
Identified by Warden code-review · XQD-K8S
Description
Issues
Reminders
tox -e linters.feat:,fix:,ref:,meta:)