MCPcopy Create free account
hub / github.com/requests-cache/requests-cache / test_non_github_requests

Function test_non_github_requests

examples/pygithub.py:79–85  ·  view source on GitHub ↗

Test that URL patterns are working, and that non-GitHub requests are not cached

()

Source from the content-addressed store, hash-verified

77
78
79def test_non_github_requests():
80 """Test that URL patterns are working, and that non-GitHub requests are not cached"""
81 response = requests.get('https://httpbin.org/json')
82 response = requests.get('https://httpbin.org/json')
83 from_cache = getattr(response, 'from_cache', False)
84 print(f'Non-GitHub requests cached: {from_cache}')
85 assert not from_cache
86
87
88def check_cache():

Callers 1

mainFunction · 0.85

Calls 1

getMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…