[Interest] Mocking Network calls in code using QNetworkAccessManager

Richard Moore rich at kde.org
Thu May 18 13:46:56 CEST 2017


On 18 May 2017 at 11:35, Shantanu Tushar <shaan7in at gmail.com> wrote:

> Any recommendations on how to do I achieve the unit test without
> needing network access?
>

​Here's an example:

​https://github.com/richmoore/qt-examples/tree/master/qcustomnetworkreply​

and a discussion of how it works:
https://blogs.kde.org/2010/08/28/implementing-reusable-custom-qnetworkreply

Regards

Rich.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20170518/16539df7/attachment.html>


More information about the Interest mailing list