Code
Hub
Workspaces
Following
Digest
Agents
Trending
Connect
MCP
copy
Index your code
hub
/
github.com/python/cpython
/ getstate
Method
getstate
Lib/test/test_descr.py:434–435 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
432
def
setstate(self, state):
433
self.state = state
434
def
getstate(self):
435
return
self.state
436
self.assertIsSubclass(C, dict)
437
a1 = C(12)
438
self.assertEqual(a1.state, 12)
Callers
14
test_spam_lists
Method · 0.95
test_spam_dicts
Method · 0.95
test_python_dicts
Method · 0.95
test_metaclass
Method · 0.95
test_multiple_inheritance
Method · 0.95
check_state_handling_decode
Method · 0.45
check_state_handling_encode
Method · 0.45
test_state_methods_with_buffer_state
Method · 0.45
test_state_methods_with_non_buffer_state
Method · 0.45
test_getstate_returns_expected_value
Method · 0.45
test_state_methods
Method · 0.45
test_autoseed
Method · 0.45
Calls
no outgoing calls
Tested by
no test coverage detected