MCPcopy Create free account

hub / github.com/requests-cache/requests-cache / functions

Functions788 in github.com/requests-cache/requests-cache

Functiontest_contains__key
(mock_session)
tests/unit/test_base_cache.py:44
Functiontest_contains__multipart_request
(mock_session)
tests/unit/test_base_cache.py:59
Functiontest_contains__request
(mock_session)
tests/unit/test_base_cache.py:51
Functiontest_contains__url
(verify, mock_session)
tests/unit/test_base_cache.py:70
Methodtest_cookies
(self)
tests/integration/base_cache_test.py:140
Functiontest_copy
()
tests/unit/test_serializers.py:137
Methodtest_corrupt_file
A corrupted file should be handled and raise a KeyError instead
tests/integration/test_mongodb.py:117
Methodtest_count
(self)
tests/integration/test_filesystem.py:357
Methodtest_count
count() should work the same as len(), but with the option to exclude expired responses
tests/integration/test_sqlite.py:369
Functiontest_create_key__fips_hash_fallback
Test that if blake2b fails due to FIPS mode, it creates a valid key using a different hash function. Fallback on TypeError and ValueError - both a
tests/unit/test_cache_keys.py:77
Functiontest_create_key__normalize_duplicate_params
()
tests/unit/test_cache_keys.py:60
Functiontest_create_key__normalize_key_only_params
()
tests/unit/test_cache_keys.py:50
Functiontest_create_key__normalize_url_params
All of the above variations should produce the same cache key
tests/unit/test_cache_keys.py:40
Methodtest_create_table_error
An error other than 'ttl already enabled' should be reraised
tests/integration/test_dynamodb.py:64
Functiontest_current
Run tests using the current virtualenv
noxfile.py:82
Methodtest_custom_extension
(self)
tests/integration/test_filesystem.py:64
Functiontest_custom_serializer
(tempfile_path)
tests/unit/test_serializers.py:100
Methodtest_db_path
This is just provided as an alias, since both requests and redirects share the same db file
tests/integration/test_sqlite.py:362
Methodtest_decode_gzip_response
Test that gzip-compressed responses read decompressed content with decode_content=True
tests/integration/base_cache_test.py:268
Methodtest_decode_json_response
Test that JSON responses (with both dict and list root) are correctly returned from the cache, regardless of `decode_content` setting
tests/integration/base_cache_test.py:284
Methodtest_decode_json_root_types
Test that JSON responses with an empty or primitive type root element are correctly returned from the cache, regardless of `decode_content` se
tests/integration/base_cache_test.py:324
Methodtest_decode_json_variants
Test that other JSON media type variants are correctly decoded and returned from the cache
tests/integration/base_cache_test.py:304
Functiontest_default_ignored_parameters
Common auth params and headers (for OAuth2, etc.) should be ignored by default
tests/unit/test_session.py:702
Methodtest_del
Some more tests to ensure ``delitem`` deletes only the expected items
tests/integration/base_storage_test.py:77
Methodtest_delete
(self)
tests/integration/test_filesystem.py:349
Functiontest_delete__cache_not_installed
(mock_delete)
tests/unit/test_patcher.py:112
Functiontest_delete__expired
(mock_normalize_url, mock_session)
tests/unit/test_base_cache.py:85
Methodtest_delete__expired
(self)
tests/integration/base_cache_test.py:348
Functiontest_delete__expired__per_request
(mock_session)
tests/unit/test_base_cache.py:118
Functiontest_delete__expired_responses
(mock_delete)
tests/unit/test_patcher.py:104
Functiontest_delete__invalid
(tempfile_path)
tests/unit/test_base_cache.py:145
Functiontest_delete__keys
(mock_session)
tests/unit/test_base_cache.py:76
Functiontest_delete__older_than
(mock_session)
tests/unit/test_base_cache.py:174
Functiontest_delete__requests
(verify, mock_session)
tests/unit/test_base_cache.py:217
Methodtest_delete__single_key
Vacuum should not be used after delete if there is only a single key
tests/integration/test_sqlite.py:379
Methodtest_delete__skip_vacuum
Vacuum should not be used after delete if disabled
tests/integration/test_sqlite.py:388
Functiontest_delete__urls
(mock_session)
tests/unit/test_base_cache.py:205
Methodtest_deleting_key_that_does_not_exist_does_not_delete_other_keys
If a key does not exist, deleting it should not delete other keys.
tests/integration/base_storage_test.py:119
Functiontest_disabled
(cached_request, original_request, installed_session)
tests/unit/test_patcher.py:77
Functiontest_do_not_cache
DO_NOT_CACHE should bypass the cache on both read and write
tests/unit/test_session.py:781
Methodtest_do_not_store_files_too_big
If a file is too big, it should not be cached at all.
tests/integration/test_filesystem.py:169
Methodtest_do_not_store_files_too_big
If a file is too big, it should not be cached at all.
tests/integration/test_filesystem.py:550
Methodtest_drop_oldest_files
Check that the files are added up to the size. After adding, the first ones are dropped.
tests/integration/test_filesystem.py:530
Methodtest_enable_ttl_error
An error other than 'table already exists' should be reraised
tests/integration/test_dynamodb.py:54
Functiontest_enabled
(cached_request, original_request, tempfile_path)
tests/unit/test_patcher.py:87
Methodtest_evict__already_deleted
Test behahior when a file is being evicted but has already been (manually) deleted on disk
tests/integration/test_filesystem.py:197
Methodtest_evict_oldest_files
Check that the files are added up to the size. After adding, the least recently used files are removed.
tests/integration/test_filesystem.py:177
Functiontest_expire_after_alias
CachedSession has an `expire_after` property for backwards-compatibility
tests/unit/test_session.py:775
Functiontest_expire_immediately
EXPIRE_IMMEDIATELY should save a response only if it has a validator
tests/unit/test_session.py:798
Functiontest_expired_request_error
Without stale_if_error (default), if there is an error while re-fetching an expired response, the request should be re-raised
tests/unit/test_session.py:494
Methodtest_file_exists
(self)
tests/integration/test_mongodb.py:127
Methodtest_filter__expired
Filtering by expired should use a more efficient SQL query
tests/integration/test_sqlite.py:421
Functiontest_filter_fn
(mock_normalize_url, mock_session)
tests/unit/test_session.py:725
Functiontest_filter_fn__retroactive
filter_fn should also apply to previously cached responses
tests/unit/test_session.py:740
Methodtest_filter_request_headers
(self, method)
tests/integration/base_cache_test.py:369
Methodtest_filter_request_post_data
(self, post_type)
tests/integration/base_cache_test.py:392
Methodtest_filter_request_query_parameters
(self, method)
tests/integration/base_cache_test.py:379
Functiontest_format_file_size
(n_bytes, expected_size)
tests/unit/models/test_response.py:172
Functiontest_from_request
(mock_session)
tests/unit/models/test_request.py:7
Functiontest_from_response
(mock_session)
tests/unit/models/test_raw_response.py:7
Functiontest_get_expiration_datetime__empty_string
An empty Expires header should raise ValueError, not IndexError
tests/unit/policy/test_expiration.py:57
Functiontest_get_expiration_datetime__httpdate
()
tests/unit/policy/test_expiration.py:50
Functiontest_get_expiration_datetime__no_expiration
(mock_datetime)
tests/unit/policy/test_expiration.py:19
Functiontest_get_expiration_datetime__relative
(expire_after, expected_expiration_delta)
tests/unit/policy/test_expiration.py:37
Functiontest_get_expiration_datetime__tzinfo
()
tests/unit/policy/test_expiration.py:44
Methodtest_get_lru
(self)
tests/integration/test_filesystem.py:383
Methodtest_get_set
(self)
tests/integration/test_filesystem.py:337
Methodtest_get_size_on_disk
Compute the block size.
tests/integration/test_filesystem.py:271
Functiontest_get_url_expiration
(url, expected_expire_after, mock_session)
tests/unit/policy/test_expiration.py:82
Functiontest_get_url_expiration__evaluation_order
If there are multiple matches, the first match should be used in the order defined
tests/unit/policy/test_expiration.py:102
Functiontest_history
(mock_session)
tests/unit/models/test_response.py:48
Functiontest_hooks
(mock_session)
tests/unit/test_session.py:759
Functiontest_https
(mock_session)
tests/unit/test_session.py:216
Functiontest_ignored_headers
Ensure that currently unimplemented Cache-Control headers do not affect behavior
tests/unit/policy/test_actions.py:649
Functiontest_ignores_nested
()
tests/unit/test_normalize.py:5
Functiontest_ignores_nested_specialcase
()
tests/unit/test_normalize.py:17
Functiontest_include_get_headers
include_get_headers is aliased to match_headers for backwards-compatibility
tests/unit/test_session.py:473
Functiontest_inheritance_after_monkey_patch
(installed_session)
tests/unit/test_patcher.py:48
Functiontest_init
Test precedence with various combinations or per-request, per-session, per-URL, and Cache-Control expiration
tests/unit/policy/test_actions.py:34
Methodtest_init__invalid_block_bytes
This block size is invalid.
tests/integration/test_filesystem.py:118
Methodtest_init__invalid_max_file_size
Cannot have file size greater than maximum cache size.
tests/integration/test_filesystem.py:127
Methodtest_init__max_file_bytes_defaults_to_max_size
The argument is initialized properly.
tests/integration/test_filesystem.py:136
Methodtest_init__shared_lock
Test passing the lock parameter.
tests/integration/test_filesystem.py:141
Functiontest_init_backend_instance
()
tests/unit/test_session.py:63
Functiontest_init_cache_path_expansion
()
tests/unit/test_session.py:74
Functiontest_init_from_headers
Test with Cache-Control request headers
tests/unit/policy/test_actions.py:65
Functiontest_init_from_headers__no_store
Test with Cache-Control request headers
tests/unit/policy/test_actions.py:78
Functiontest_init_from_settings
Test with per-session, per-request, and per-URL expiration
tests/unit/policy/test_actions.py:106
Functiontest_init_from_settings_and_headers
Test behavior with both cache settings and request headers.
tests/unit/policy/test_actions.py:137
Functiontest_init_missing_backend_dependency
Test that the correct error is thrown when a user does not have a dependency installed
tests/unit/test_session.py:80
Functiontest_init_unregistered_backend
()
tests/unit/test_session.py:69
Functiontest_install_uninstall
()
tests/unit/test_patcher.py:12
Functiontest_invalid_expiration
(mock_session)
tests/unit/test_session.py:853
Functiontest_is_expired
(expires, is_expired, mock_session)
tests/unit/models/test_response.py:63
Functiontest_is_expired__timezone_naive
(mock_session)
tests/unit/models/test_response.py:69
Functiontest_is_installed
()
tests/unit/test_patcher.py:95
Functiontest_is_usable__max_stale
For a response that expired 10 seconds ago, it may be either accepted or rejected based on max-stale
tests/unit/policy/test_actions.py:493
Functiontest_is_usable__min_fresh
For a response that expires in 10 seconds, it may be either accepted or rejected based on min-fresh
tests/unit/policy/test_actions.py:507
Functiontest_is_usable__stale_if_error
For a response that expired 10 seconds ago, if an error occurred while refreshing, it may be either accepted or rejected based on stale-if-error
tests/unit/policy/test_actions.py:528
Functiontest_is_usable__stale_while_revalidate
For a response that expired 10 seconds ago, if an error occurred while refreshing, it may be either accepted or rejected based on stale-while-reva
tests/unit/policy/test_actions.py:548
← previousnext →501–600 of 788, ranked by callers