Skip to content

Commit

Permalink
Testing applying of the comms::option::def::FixedValue option to comm…
Browse files Browse the repository at this point in the history
…s::field::BitmaskValue.
  • Loading branch information
arobenko committed Oct 28, 2024
1 parent ca2d43d commit c93bad4
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions test/Fields2.th
Original file line number Diff line number Diff line change
Expand Up @@ -2245,6 +2245,7 @@ void FieldsTestSuite2::test38()
comms::field::BitmaskValue<
comms::Field<BigEndianOpt>,
comms::option::def::FixedLength<1>,
comms::option::def::FixedValue,
comms::option::def::BitmaskReservedBits<0xff, 0x1>,
comms::option::def::DefaultNumValue<0x1>
>;
Expand All @@ -2253,6 +2254,8 @@ void FieldsTestSuite2::test38()
TS_ASSERT(field.valid());
TS_ASSERT_EQUALS(field.getBitValue(0), true);
TS_ASSERT_EQUALS(field.getBitValue(1), false);

// field.setBitValue(1, true); // Must fail compilation
}

template <typename TField>
Expand Down

0 comments on commit c93bad4

Please sign in to comment.