MCPcopy Create free account
hub / github.com/Tencent/MMKV / test_long_uint

Function test_long_uint

Python/unit_test.py:92–106  ·  view source on GitHub ↗
(kv)

Source from the content-addressed store, hash-verified

90
91
92def test_long_uint(kv):
93 MaxLongUInt = (2 ** 64) - 1
94 ret = kv.set(MaxLongUInt, 'LongUInt')
95 assert ret
96
97 value = kv.getLongUInt('LongUInt')
98 assert value == MaxLongUInt
99
100 value = kv.getLongUInt(KeyNotExist)
101 assert value == 0
102
103 value = kv.getLongUInt(KeyNotExist, 1)
104 assert value == 1
105
106 print('test long unsigned int: passed')
107
108
109def is_float_equal(a, b, accuracy=1e-09):

Callers 1

unit_test.pyFile · 0.85

Calls 1

setMethod · 0.45

Tested by

no test coverage detected