MCPcopy Create free account
hub / github.com/argotorg/solidity / BOOST_AUTO_TEST_CASE

Function BOOST_AUTO_TEST_CASE

test/libsolutil/FixedHash.cpp:37–71  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35BOOST_AUTO_TEST_SUITE(FixedHashTest)
36
37BOOST_AUTO_TEST_CASE(default_constructor)
38{
39 BOOST_CHECK_EQUAL(
40 FixedHash<1>{}.hex(),
41 "00"
42 );
43 BOOST_CHECK_EQUAL(
44 FixedHash<1>{}.size,
45 1
46 );
47 BOOST_CHECK_EQUAL(
48 FixedHash<8>{}.hex(),
49 "0000000000000000"
50 );
51 BOOST_CHECK_EQUAL(
52 FixedHash<8>{}.size,
53 8
54 );
55 BOOST_CHECK_EQUAL(
56 FixedHash<20>{}.hex(),
57 "0000000000000000000000000000000000000000"
58 );
59 BOOST_CHECK_EQUAL(
60 FixedHash<20>{}.size,
61 20
62 );
63 BOOST_CHECK_EQUAL(
64 FixedHash<32>{}.hex(),
65 "0000000000000000000000000000000000000000000000000000000000000000"
66 );
67 BOOST_CHECK_EQUAL(
68 FixedHash<32>{}.size,
69 32
70 );
71}
72
73BOOST_AUTO_TEST_CASE(bytes_constructor)
74{

Callers

nothing calls this directly

Calls 5

hexMethod · 0.80
asBytesMethod · 0.80
refMethod · 0.80
strMethod · 0.80
dataMethod · 0.45

Tested by

no test coverage detected