[Libreoffice-commits] online.git: Branch 'feature/latency2' - test/TileCacheTests.cpp

Tamás Zolnai tamas.zolnai at collabora.com
Fri Jul 13 15:23:51 UTC 2018


 test/TileCacheTests.cpp |    4 ++++
 1 file changed, 4 insertions(+)

New commits:
commit 81eac4e5a9c9575ad3b1d6fecc738d3d0f21c5ef
Author: Tamás Zolnai <tamas.zolnai at collabora.com>
Date:   Fri Jul 13 17:22:42 2018 +0200

    Fix failing unit tests after latency changes
    
    With the new code, wsd is waiting for tileprocessed messages
    if the upper limit of tiles-on-limit is reached. To avoid that
    send canceltiles message so tile message are send.
    
    Change-Id: Iadf16c834f12d14000d630078882dfa8e11a99a0

diff --git a/test/TileCacheTests.cpp b/test/TileCacheTests.cpp
index 10d8ba648..09fe0671e 100644
--- a/test/TileCacheTests.cpp
+++ b/test/TileCacheTests.cpp
@@ -247,6 +247,8 @@ void TileCacheTests::testPerformance()
             std::vector<char> tile = getResponseMessage(socket, "tile:", "tile-performance ");
             CPPUNIT_ASSERT_MESSAGE("did not receive a tile: message as expected", !tile.empty());
         }
+        /// Send canceltiles message to clear tiles-on-fly list, otherwise wsd waits for tileprocessed messages
+        sendTextFrame(socket, "canceltiles");
     }
 
     std::cerr << "Tile rendering roundtrip for 5 x 8 tiles combined: " << timestamp.elapsed() / 1000.
@@ -430,6 +432,8 @@ void TileCacheTests::testUnresponsiveClient()
             std::vector<char> tile = getResponseMessage(socket2, "tile:", "client2 ");
             CPPUNIT_ASSERT_MESSAGE("Did not receive tile #" + std::to_string(i+1) + " of 8: message as expected", !tile.empty());
         }
+        /// Send canceltiles message to clear tiles-on-fly list, otherwise wsd waits for tileprocessed messages
+        sendTextFrame(socket2, "canceltiles");
     }
 }
 


More information about the Libreoffice-commits mailing list