Details
Description
This test is flaky only on Windows and 5.12 branch AFAICT, so I'm setting the priority to low.
agent:2020/03/09 16:14:56 build.go:253: FAIL! : tst_QTcpSocket::increaseReadBufferSize(WithoutProxy SSL) Compared values are not the same agent:2020/03/09 16:14:56 build.go:253: Actual (active->bytesAvailable()): 512 agent:2020/03/09 16:14:56 build.go:253: Expected (active->readBufferSize()): 256 agent:2020/03/09 16:14:56 build.go:253: ..\tst_qtcpsocket.cpp(2615) : failure location
The code in question:
2597 // connect two sockets to each other: 2598 QVERIFY(server.listen(QHostAddress::LocalHost)); 2599 active->connectToHost("127.0.0.1", server.serverPort()); 2600 QVERIFY(active->waitForConnected(5000)); 2601 QVERIFY(server.waitForNewConnection(5000)); 2602 2603 QTcpSocket *passive = server.nextPendingConnection(); 2604 QVERIFY(passive); 2605 2606 // now write 512 bytes of data on one end 2607 QByteArray data(512, 'a'); 2608 passive->write(data); 2609 QVERIFY2(passive->waitForBytesWritten(5000), "Network timeout"); 2610 2611 // set the read buffer size to less than what was written and iterate: 2612 active->setReadBufferSize(256); 2613 enterLoop(10); 2614 QVERIFY2(!timeout(), "Network timeout"); 2615 QCOMPARE(active->bytesAvailable(), active->readBufferSize());
How is it possible to have 512 bytes available when the buffer size is 256?
Attachments
Issue Links
- relates to
-
QTBUG-82835 Stale socket notifications can be emitted to new sockets
-
- Closed
-
For Gerrit Dashboard: QTBUG-82776 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
293499,3 | TCP socket auto-test: reduce flakyness | 5.12 | qt/qtbase | Status: MERGED | +2 | 0 |