Name Description Size Coverage
platforminputcontext_p.h 2503 -
platformquirks_p.h 1545 -
qmlutils.cpp 5508 -
qmlutils_p.h Base class for tests with data that are located in a "data" subfolder. 5432 -
testhttpserver.cpp ! \internal \class TestHTTPServer \brief provides a very, very basic HTTP server for testing. Inside the test case, an instance of TestHTTPServer should be created, with the appropriate port to listen on. The server will listen on the localhost interface. Directories to serve can then be added to server, which will be added as "roots". Each root can be added as a Normal, Delay or Disconnect root. Requests for files within a Normal root are returned immediately. Request for files within a Delay root are delayed for 500ms, and then served. Requests for files within a Disconnect directory cause the server to disconnect immediately. A request for a file that isn't found in any root will return a 404 error. If you have the following directory structure: \code disconnect/disconnectTest.qml files/main.qml files/Button.qml files/content/WebView.qml slowFiles/slowMain.qml \endcode it can be added like this: \code TestHTTPServer server; QVERIFY2(server.listen(14445), qPrintable(server.errorString())); server.serveDirectory("disconnect", TestHTTPServer::Disconnect); server.serveDirectory("files"); server.serveDirectory("slowFiles", TestHTTPServer::Delay); \endcode The following request urls will then result in the appropriate action: \table \header \li URL \li Action \row \li http://localhost:14445/disconnectTest.qml \li Disconnection \row \li http://localhost:14445/main.qml \li main.qml returned immediately \row \li http://localhost:14445/Button.qml \li Button.qml returned immediately \row \li http://localhost:14445/content/WebView.qml \li content/WebView.qml returned immediately \row \li http://localhost:14445/slowMain.qml \li slowMain.qml returned after 500ms \endtable 13861 -
testhttpserver_p.h 3232 -