MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / TEST

Function TEST

src/leveldb/util/coding_test.cc:13–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

11class Coding { };
12
13TEST(Coding, Fixed32) {
14 std::string s;
15 for (uint32_t v = 0; v < 100000; v++) {
16 PutFixed32(&s, v);
17 }
18
19 const char* p = s.data();
20 for (uint32_t v = 0; v < 100000; v++) {
21 uint32_t actual = DecodeFixed32(p);
22 ASSERT_EQ(v, actual);
23 p += sizeof(uint32_t);
24 }
25}
26
27TEST(Coding, Fixed64) {
28 std::string s;

Callers

nothing calls this directly

Calls 15

PutFixed32Function · 0.85
DecodeFixed32Function · 0.85
PutFixed64Function · 0.85
DecodeFixed64Function · 0.85
PutVarint32Function · 0.85
GetVarint32PtrFunction · 0.85
VarintLengthFunction · 0.85
PutVarint64Function · 0.85
GetVarint64PtrFunction · 0.85
PutLengthPrefixedSliceFunction · 0.85
SliceClass · 0.70
GetLengthPrefixedSliceFunction · 0.70

Tested by

no test coverage detected