let auto tests of batch upload return proper file paths
authorMatthieu Gallien <matthieu.gallien@nextcloud.com>
Thu, 25 Nov 2021 15:46:10 +0000 (16:46 +0100)
committerMatthieu Gallien <matthieu.gallien@nextcloud.com>
Fri, 26 Nov 2021 14:49:25 +0000 (15:49 +0100)
Signed-off-by: Matthieu Gallien <matthieu.gallien@nextcloud.com>
test/syncenginetestutils.cpp

index 83af262beba3327e7ad6134ce41aa052a229f5ed..53369d020134a4af77f14d69c7e5557db61cba65 100644 (file)
@@ -488,7 +488,7 @@ void FakePutMultiFileReply::respond()
         fileInfoReply.insert("OC-FileID", QLatin1String{fileInfo->fileId});
         fileInfoReply.insert("X-OC-MTime", "accepted"); // Prevents Q_ASSERT(!_runningNow) since we'll call PropagateItemJob::done twice in that case.
         emit uploadProgress(fileInfo->size, totalSize);
-        allFileInfoReply.insert(fileInfo->path(), fileInfoReply);
+        allFileInfoReply.insert(QChar('/') + fileInfo->path(), fileInfoReply);
     }
     reply.setObject(allFileInfoReply);
     _payload = reply.toJson();