Skip to content

Commit 7cf9b83

Browse files
committed
Add point test cases.
1 parent 9aa8055 commit 7cf9b83

1 file changed

Lines changed: 15 additions & 2 deletions

File tree

test/chain/point.cpp

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,21 @@ BOOST_AUTO_TEST_CASE(point__to_data__writer__expected)
162162
// properties
163163
// ----------------------------------------------------------------------------
164164

165-
// is_null
166-
// serialized_size
165+
BOOST_AUTO_TEST_CASE(point__is_null__not_null__false)
166+
{
167+
BOOST_REQUIRE(!expected_point.is_null());
168+
}
169+
170+
BOOST_AUTO_TEST_CASE(point__is_null__default_null__true)
171+
{
172+
BOOST_REQUIRE(point{}.is_null());
173+
}
174+
175+
BOOST_AUTO_TEST_CASE(point__serialized_size__always__expected)
176+
{
177+
static_assert(point::serialized_size() == hash_size + sizeof(uint32_t));
178+
BOOST_REQUIRE_EQUAL(point::serialized_size(), hash_size + sizeof(uint32_t));
179+
}
167180

168181
// json
169182
// ----------------------------------------------------------------------------

0 commit comments

Comments
 (0)