We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ba86aef commit ab4a66cCopy full SHA for ab4a66c
test/src/CanMsg/test_CanMsg.cpp
@@ -50,3 +50,17 @@ TEST_CASE ("Test constructor with data (data length > CanMsg::MAX_DATA_LENGTH)",
50
for (size_t i = 0; i < msg.data_length; i++)
51
REQUIRE(msg.data[i] == msg_data[i]);
52
}
53
+
54
+TEST_CASE ("Test constructor constructing a CAN frame with standard ID", "[CanMsg-CanMsg-04]")
55
+{
56
+ CanMsg const msg(CanStandardId(0x20), 0, nullptr);
57
58
+ REQUIRE(msg.id == 0x20);
59
+}
60
61
+TEST_CASE ("Test constructor constructing a CAN frame with extended ID", "[CanMsg-CanMsg-05]")
62
63
+ CanMsg const msg(CanExtendedId(0x20), 0, nullptr);
64
65
+ REQUIRE(msg.id == (CanMsg::CAN_EFF_FLAG | 0x20));
66
AltStyle によって変換されたページ (->オリジナル) / アドレス: モード: デフォルト 音声ブラウザ ルビ付き 配色反転 文字拡大 モバイル
0 commit comments