MCPcopy Create free account
hub / github.com/crayzeewulf/libserial / testSerialPortIsOpenTest

Method testSerialPortIsOpenTest

test/SerialPortUnitTests.cpp:323–340  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

321}
322
323void
324SerialPortUnitTests::testSerialPortIsOpenTest()
325{
326 ASSERT_FALSE(serialPort1.IsOpen()) ;
327 ASSERT_FALSE(serialPort2.IsOpen()) ;
328
329 serialPort1.Open(TEST_SERIAL_PORT_1) ;
330 serialPort2.Open(TEST_SERIAL_PORT_2) ;
331
332 ASSERT_TRUE(serialPort1.IsOpen()) ;
333 ASSERT_TRUE(serialPort2.IsOpen()) ;
334
335 serialPort1.Close() ;
336 serialPort2.Close() ;
337
338 ASSERT_FALSE(serialPort1.IsOpen()) ;
339 ASSERT_FALSE(serialPort2.IsOpen()) ;
340}
341
342void
343SerialPortUnitTests::testSerialPortSetGetBaudRate()

Callers

nothing calls this directly

Calls 3

IsOpenMethod · 0.45
OpenMethod · 0.45
CloseMethod · 0.45

Tested by

no test coverage detected