MCPcopy Create free account
hub / github.com/avast/retdec / TEST_F

Function TEST_F

tests/serdes/pattern_tests.cpp:38–51  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36};
37
38TEST_F(PatternMatchItemTests, getJsonValueWorksWithFromJsonValueWithFullyDefinedMatch)
39{
40 auto m1 = common::Pattern::Match::floatingPoint(0x1000, 0x2000, 0x100, 4);
41 serialize(writer, m1);
42 root.Parse(sb.GetString());
43 common::Pattern::Match m2;
44 deserialize(root, m2);
45
46 EXPECT_TRUE(m2.isTypeFloatingPoint());
47 EXPECT_EQ(0x1000, m2.getOffset());
48 EXPECT_EQ(0x2000, m2.getAddress());
49 EXPECT_EQ(0x100, m2.getSize());
50 EXPECT_EQ(4, m2.getEntrySize());
51}
52
53TEST_F(PatternMatchItemTests, getJsonValueWorksWithFromJsonValueWithPartiallyDefinedMatch)
54{

Callers

nothing calls this directly

Calls 15

isTypeFloatingPointMethod · 0.80
isAddressDefinedMethod · 0.80
isSizeDefinedMethod · 0.80
isEntrySizeDefinedMethod · 0.80
isTypeMalwareMethod · 0.80
serializeFunction · 0.50
deserializeFunction · 0.50
ParseMethod · 0.45
getOffsetMethod · 0.45
getAddressMethod · 0.45
getSizeMethod · 0.45
getEntrySizeMethod · 0.45

Tested by

no test coverage detected