34 #include "gtest/gtest.h" 36 #include <boost/shared_ptr.hpp> 38 TEST(SerialStreamTest, Constructor)
40 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
44 TEST(SerialStreamTest, Connected)
46 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
50 EXPECT_FALSE(serial_stream.connected());
53 TEST(SerialStreamTest, Disconnect)
55 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
59 serial_stream.disconnect();
62 TEST(SerialStreamTest, NumPackets)
64 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
68 EXPECT_EQ(serial_stream.getNumCorruptPackets(), 0);
69 EXPECT_EQ(serial_stream.getTotalPackets(), 0);
72 TEST(SerialStreamTest, Send)
74 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
80 EXPECT_FALSE(serial_stream.send(bytes, 4));
83 TEST(SerialStreamTest, SendOpcode)
85 boost::shared_ptr<create::Data> data_ptr = boost::make_shared<create::Data>();
TEST(SerialStreamTest, Constructor)