MCPcopy Create free account
hub / github.com/dask/dask / test_staticmethods

Function test_staticmethods

dask/tests/test_tokenize.py:820–829  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

818
819
820def test_staticmethods():
821 a, b, c = HasStaticMethods(1), HasStaticMethods(2), HasStaticMethods2(1)
822 # These invoke HasStaticMethods.__dask_tokenize__()
823 assert check_tokenize(a.normal_method) != check_tokenize(b.normal_method)
824 assert check_tokenize(a.normal_method) != check_tokenize(c.normal_method)
825 # These don't
826 assert check_tokenize(a.static_method) == check_tokenize(b.static_method)
827 assert check_tokenize(a.static_method) == check_tokenize(c.static_method)
828 assert check_tokenize(a.class_method) == check_tokenize(b.class_method)
829 assert check_tokenize(a.class_method) != check_tokenize(c.class_method)
830
831
832def test_tokenize_sequences():

Callers

nothing calls this directly

Calls 3

HasStaticMethodsClass · 0.85
HasStaticMethods2Class · 0.85
check_tokenizeFunction · 0.85

Tested by

no test coverage detected