diff ui/tests/downloadertest.cpp @ 46:d28e2624c1d5

Reset connection before the next request. This makes the downloader work for the first simple test.
author Andre Heinecke <aheinecke@intevation.de>
date Mon, 17 Mar 2014 10:51:47 +0000
parents c6125d73faf4
children 7e37c6033c81
line wrap: on
line diff
--- a/ui/tests/downloadertest.cpp	Fri Mar 14 16:40:53 2014 +0000
+++ b/ui/tests/downloadertest.cpp	Mon Mar 17 10:51:47 2014 +0000
@@ -26,7 +26,7 @@
         "Interface = 127.0.0.1" << endl <<
         "}" << endl <<
         "Hostname = 127.0.0.1" << endl <<
-        "WebsiteRoot = " << SOURCE_DIR << endl;
+        "WebsiteRoot = " << SOURCE_DIR << "/data" << endl;
     configStream.flush();
 
     serverConfig.close();
@@ -60,8 +60,8 @@
             validCert.readAll(),
             QDateTime::currentDateTime(), // Last installed SW
             QDateTime::fromString("2010", "YYYY"),
-            "/list-valid.txt",
-            "/random_2MB");
+            "/random_2MB",
+            "/list-valid.txt");
     validCert.close();
 
     QSignalSpy newListAvailable(downloader,
@@ -78,7 +78,7 @@
     int waited = 0;
     while (newListAvailable.count() == 0 &&
             errors.count() == 0  && waited < 20) {
-        QTest::qWait(200);
+        QTest::qWait(2000);
         waited++;
     }
     QVERIFY(waited != 20);

http://wald.intevation.org/projects/trustbridge/