MCPcopy
hub / github.com/redis/redis-py / test_create

Function test_create

tests/test_bloom.py:40–51  ·  view source on GitHub ↗

Test CREATE/RESERVE calls

(client)

Source from the content-addressed store, hash-verified

38
39@pytest.mark.redismod
40def test_create(client):
41 """Test CREATE/RESERVE calls"""
42 assert client.bf().create("bloom", 0.01, 1000)
43 assert client.bf().create("bloom_e", 0.01, 1000, expansion=1)
44 assert client.bf().create("bloom_ns", 0.01, 1000, noScale=True)
45 assert client.cf().create("cuckoo", 1000)
46 assert client.cf().create("cuckoo_e", 1000, expansion=1)
47 assert client.cf().create("cuckoo_bs", 1000, bucket_size=4)
48 assert client.cf().create("cuckoo_mi", 1000, max_iterations=10)
49 assert client.cms().initbydim("cmsDim", 100, 5)
50 assert client.cms().initbyprob("cmsProb", 0.01, 0.01)
51 assert client.topk().reserve("topk", 5, 100, 5, 0.9)
52
53
54@pytest.mark.redismod

Callers

nothing calls this directly

Calls 8

initbydimMethod · 0.80
initbyprobMethod · 0.80
reserveMethod · 0.80
createMethod · 0.45
bfMethod · 0.45
cfMethod · 0.45
cmsMethod · 0.45
topkMethod · 0.45

Tested by

no test coverage detected