MCPcopy Create free account
hub / github.com/RedisGraph/RedisGraph / test_hashLong

Function test_hashLong

tests/unit/test_value.c:91–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91void test_hashLong() {
92 // INT32 and INT64 tests take too long
93 for(int64_t i = 0; i < 100; i++) {
94 int num = rand();
95 SIValue siInt64 = SI_LongVal(num);
96 SIValue siInt64Other = SI_LongVal(num);
97 uint64_t origHashCode = SIValue_HashCode(siInt64);
98 uint64_t otherHashCode = SIValue_HashCode(siInt64Other);
99 TEST_ASSERT(origHashCode == otherHashCode);
100 }
101}
102
103void test_hashDouble() {
104 SIValue siDouble = SI_DoubleVal(3.14);

Callers

nothing calls this directly

Calls 2

SI_LongValFunction · 0.85
SIValue_HashCodeFunction · 0.85

Tested by

no test coverage detected