[
https://issues.apache.org/jira/browse/THRIFT-3566?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15104957#comment-15104957
]
ASF GitHub Bot commented on THRIFT-3566:
----------------------------------------
GitHub user szenker opened a pull request:
https://github.com/apache/thrift/pull/804
THRIFT-3566: fixed TQTcpServerTest - it was never executed and working
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/szenker/thrift THRIFT-3566
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/thrift/pull/804.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #804
----
commit c6e18e506d24123e323b2a190d8ddddc01ae572c
Author: Sebastian Zenker <[email protected]>
Date: 2016-01-18T07:37:54Z
C++/Qt: TQTcpServerTest did never execute the actual test method
test_communicate() as it wasn't declared as a Qt slot. The test gets now
executed but it is broken because server and (synchronous) client cannot be
executed in the same thread.
commit 9bfd6f322a9b87e93490c669fda448f8097fed3b
Author: Sebastian Zenker <[email protected]>
Date: 2016-01-18T07:38:23Z
C++/Qt: TQTcpServerTest: converted class members into local variables which
don't need to be part of the test class
commit 0e0708571d312b7f5fe826fa2bb919f2246fe88e
Author: Sebastian Zenker <[email protected]>
Date: 2016-01-18T07:39:07Z
C++/Qt: fixed TQTcpServerTest by moving the server into it's own thread
----
> C++/Qt: TQTcpServerTest::test_communicate() is never executed
> -------------------------------------------------------------
>
> Key: THRIFT-3566
> URL: https://issues.apache.org/jira/browse/THRIFT-3566
> Project: Thrift
> Issue Type: Bug
> Components: C++ - Library
> Affects Versions: 0.9.3, 0.9.4, 1.0
> Reporter: Sebastian Zenker
> Priority: Minor
>
> The unit test is broken/never executed because of the following three reasons:
> 1. TQTcpServerTest::test_communicate() needs to be declared as Qt slot,
> otherwise the QTest-framework would never execute it. This explains why the
> unit test always succeeded :-)
> 2. The server and synchronous client cannot be executed in the same thread,
> as the server requires the mainloop to run
> 3. The expected response from the server is "foo, bar" and not "foo, foo".
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)