summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenis Shienkov <denis.shienkov@gmail.com>2015-09-10 12:02:45 +0300
committerDenis Shienkov <denis.shienkov@gmail.com>2015-09-10 13:59:41 +0000
commit64f756d45c55c04ac3decf3976a8fb241d543f3b (patch)
tree8334f952b362d2edaa7dfd854893431f7b5faae4
parent9ca188fea79e3909ab09d3a335ce84ca5330fa9b (diff)
downloadqtserialport-64f756d45c55c04ac3decf3976a8fb241d543f3b.tar.gz
Open the dummy device for tests on any platform
The virtual serial port drivers (such as com0com or tty0tty) require all pairs of devices were open, otherwise any I/O will fails. Seems, it is feature of com0com and tty0tty drivers, and maybe others drivers of virtual devices. There is only one waitForReadyReadWithTimeout() test which opens the dummy device only in Windows. So, it is necessary to open the dummy device on any platform. (cherry-picked from 7fbc7cefcada03aa455bda305734663cf2b6a117) Change-Id: I472238704fe200309b5015c2f9740d8e4b6cb41f Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
-rw-r--r--tests/auto/qserialport/tst_qserialport.cpp2
1 files changed, 0 insertions, 2 deletions
diff --git a/tests/auto/qserialport/tst_qserialport.cpp b/tests/auto/qserialport/tst_qserialport.cpp
index c14976d..74eec3d 100644
--- a/tests/auto/qserialport/tst_qserialport.cpp
+++ b/tests/auto/qserialport/tst_qserialport.cpp
@@ -556,11 +556,9 @@ void tst_QSerialPort::waitForBytesWritten()
void tst_QSerialPort::waitForReadyReadWithTimeout()
{
-#ifdef Q_OS_WIN
// the dummy device on other side also has to be open
QSerialPort dummySerialPort(m_senderPortName);
QVERIFY(dummySerialPort.open(QIODevice::WriteOnly));
-#endif
QSerialPort receiverSerialPort(m_receiverPortName);
QVERIFY(receiverSerialPort.open(QIODevice::ReadOnly));