Repository navigation
Record real API response - #523
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #523 +/- ##
==========================================
+ Coverage 94.73% 95.29% +0.56%
==========================================
Files 59 59
Lines 2676 2676
==========================================
+ Hits 2535 2550 +15
+ Misses 141 126 -15 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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.
I'll help you generate a PR description against the master branch. First, let me check the current state of the repository and understand what changes have been made.
Based on my analysis of the repository, I can see this PR adds comprehensive integration tests using VCR (Video Cassette Recorder) to record and replay real Wikipedia API responses. Here's the PR description:
Add Comprehensive Integration Tests with VCR
Summary
This PR introduces a comprehensive integration test suite using VCR (Video Cassette Recorder) to record real Wikipedia API responses and replay them during tests. This provides fast, deterministic testing while ensuring the library works correctly against the actual Wikipedia API.
What's Added
🧪 New Integration Test Infrastructure
make run-tests-integrationfor running integration tests📁 Test Files Added
tests/vcr_page_sync_test.py- Synchronous page API teststests/vcr_page_async_test.py- Asynchronous page API teststests/vcr_wiki_client_async_test.py- Asynchronous wiki client teststests/vcr_pages_dict_sync_test.py- Synchronous pages dict teststests/vcr_pages_dict_async_test.py- Asynchronous pages dict tests🎯 Coverage
Benefits
⚡ Performance
🛡️ Reliability
🔍 Comprehensive Coverage
Usage
Running Integration Tests
Recording New Cassettes
Technical Details
VCR Configuration
tests/cassettes/once(record if missing, replay if exists)Test Structure
Files Changed
📝 Configuration
run-tests-integrationtargetpyproject.toml- Added VCR dependencytox.ini- Updated test configuration🧪 Tests Added
Verification
This integration test suite ensures the Wikipedia-API library continues to work correctly with real Wikipedia API responses while providing fast, reliable testing for developers and CI/CD pipelines.