Hello community, here is the log from the commit of package baloo5 for openSUSE:Factory checked in at 2016-11-17 12:25:41 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/baloo5 (Old) and /work/SRC/openSUSE:Factory/.baloo5.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "baloo5" Changes: -------- --- /work/SRC/openSUSE:Factory/baloo5/baloo5.changes 2016-10-28 12:15:13.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.baloo5.new/baloo5.changes 2016-11-17 12:25:42.000000000 +0100 @@ -1,0 +2,7 @@ +Sat Nov 5 20:04:27 UTC 2016 - [email protected] + +- Update to 5.28.0 + * For more details please see: + https://www.kde.org/announcements/kde-frameworks-5.28.0.php + +------------------------------------------------------------------- Old: ---- baloo-5.27.0.tar.xz New: ---- baloo-5.28.0.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ baloo5.spec ++++++ --- /var/tmp/diff_new_pack.HAG73K/_old 2016-11-17 12:25:43.000000000 +0100 +++ /var/tmp/diff_new_pack.HAG73K/_new 2016-11-17 12:25:43.000000000 +0100 @@ -17,9 +17,9 @@ %bcond_without lang -%define _tar_path 5.27 +%define _tar_path 5.28 Name: baloo5 -Version: 5.27.0 +Version: 5.28.0 Release: 0 %define kf5_version %{version} Summary: Framework for searching and managing metadata ++++++ baloo-5.27.0.tar.xz -> baloo-5.28.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/CMakeLists.txt new/baloo-5.28.0/CMakeLists.txt --- old/baloo-5.27.0/CMakeLists.txt 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/CMakeLists.txt 2016-11-05 15:40:23.000000000 +0100 @@ -1,8 +1,8 @@ # set minimum version requirements cmake_minimum_required(VERSION 2.8.12) set(REQUIRED_QT_VERSION 5.5.0) -set(KF5_VERSION "5.27.0") # handled by release scripts -set(KF5_DEP_VERSION "5.27.0") # handled by release scripts +set(KF5_VERSION "5.28.0") # handled by release scripts +set(KF5_DEP_VERSION "5.28.0") # handled by release scripts # set up project project(Baloo) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/autotests/benchmarks/positioncodecbenchmark.cpp new/baloo-5.28.0/autotests/benchmarks/positioncodecbenchmark.cpp --- old/baloo-5.27.0/autotests/benchmarks/positioncodecbenchmark.cpp 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/autotests/benchmarks/positioncodecbenchmark.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -30,26 +30,68 @@ { Q_OBJECT private Q_SLOTS: - void test(); + void initTestCase(); + // data 1 - a lot of positions, small amount of PositionInfo + void benchEncodeData1(); + void benchDecodeData1(); + // data 2 - few positions, large amount of PositionInfo + void benchEncodeData2(); + void benchDecodeData2(); +private: + QVector<PositionInfo> m_benchmarkData1; + QVector<PositionInfo> m_benchmarkData2; }; -void PositionCodecBenchmark::test() +void PositionCodecBenchmark::initTestCase() { - PositionCodec codec; + m_benchmarkData1.clear(); + m_benchmarkData1.reserve(100); + for(int i = 0; i < 100; ++i) + { + PositionInfo info; + info.docId = (i + 1) * 4711; + info.positions.reserve(3000); + for (int j = 0; j < 3000; j++) + info.positions.append(((j + 1) * 42) / info.docId); + m_benchmarkData1.append(info); + } - QVector<PositionInfo> vec; + m_benchmarkData2.clear(); + m_benchmarkData2.reserve(5000); for (int i = 0; i < 5000; i++) { PositionInfo info; info.docId = i; info.positions = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}; - vec << info; + m_benchmarkData2.append(info); } - QBENCHMARK { - QByteArray data = codec.encode(vec); - codec.decode(data); - } +} + +void PositionCodecBenchmark::benchEncodeData1() +{ + PositionCodec pc; + QBENCHMARK { pc.encode(m_benchmarkData1); } +} + +void PositionCodecBenchmark::benchDecodeData1() +{ + PositionCodec pc; + const QByteArray ba = pc.encode(m_benchmarkData1); + QBENCHMARK { pc.decode(ba); } +} + +void PositionCodecBenchmark::benchEncodeData2() +{ + PositionCodec pc; + QBENCHMARK { pc.encode(m_benchmarkData2); } +} + +void PositionCodecBenchmark::benchDecodeData2() +{ + PositionCodec pc; + const QByteArray ba = pc.encode(m_benchmarkData2); + QBENCHMARK { pc.decode(ba); } } QTEST_MAIN(PositionCodecBenchmark) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/autotests/unit/codecs/CMakeLists.txt new/baloo-5.28.0/autotests/unit/codecs/CMakeLists.txt --- old/baloo-5.27.0/autotests/unit/codecs/CMakeLists.txt 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/autotests/unit/codecs/CMakeLists.txt 2016-11-05 15:40:23.000000000 +0100 @@ -10,4 +10,5 @@ baloo_codecs_auto_tests( doctermscodectest postingcodectest + positioncodectest ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/autotests/unit/codecs/positioncodectest.cpp new/baloo-5.28.0/autotests/unit/codecs/positioncodectest.cpp --- old/baloo-5.27.0/autotests/unit/codecs/positioncodectest.cpp 1970-01-01 01:00:00.000000000 +0100 +++ new/baloo-5.28.0/autotests/unit/codecs/positioncodectest.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -0,0 +1,71 @@ +/* + This file is part of the KDE Baloo project. + Copyright (C) 2016 Christian Ehrlicher <[email protected]> + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Lesser General Public + License as published by the Free Software Foundation; either + version 2.1 of the License, or (at your option) version 3, or any + later version accepted by the membership of KDE e.V. (or its + successor approved by the membership of KDE e.V.), which shall + act as a proxy defined in Section 6 of version 3 of the license. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Lesser General Public License for more details. + + You should have received a copy of the GNU Lesser General Public + License along with this library. If not, see <http://www.gnu.org/licenses/>. +*/ + +#include <QCryptographicHash> +#include <QtTest> +#include "positioncodec.h" +#include "positioninfo.h" + +using namespace Baloo; + +class PositionCodecTest : public QObject +{ +Q_OBJECT +public: + PositionCodecTest() = default; + ~PositionCodecTest() = default; +private Q_SLOTS: + void initTestCase(); + void checkEncodeOutput(); +private: + QVector<PositionInfo> m_data; +}; + +QTEST_MAIN ( PositionCodecTest ) + +void PositionCodecTest::initTestCase() +{ + m_data.clear(); + m_data.reserve(100); + for(int i = 0; i < 100; ++i) + { + PositionInfo info; + info.docId = (i + 1) * 4711; + info.positions.reserve(3000); + for (int j = 0; j < 3000; j++) + info.positions.append(((j + 1) * 42) / info.docId); + m_data.append(info); + } +} + +void PositionCodecTest::checkEncodeOutput() +{ + PositionCodec pc; + const QByteArray ba = pc.encode(m_data); + QCOMPARE(ba.size(), 301000); + const QByteArray md5 = QCryptographicHash::hash(ba, QCryptographicHash::Md5).toHex(); + QCOMPARE(md5, QByteArray("d44a606d301937bef105411c0ee77a88")); + // and now decode the whole stuff + QVector<PositionInfo> decodedData = pc.decode(ba); + QCOMPARE(m_data, decodedData); +} + +#include "positioncodectest.moc" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/src/engine/transaction.cpp new/baloo-5.28.0/src/engine/transaction.cpp --- old/baloo-5.27.0/src/engine/transaction.cpp 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/src/engine/transaction.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -454,9 +454,8 @@ auto map = postingDb.toTestMap(); - QList<PostingList> allLists = map.values(); QSet<quint64> allIds; - for (auto list : allLists) { + Q_FOREACH (const auto& list, map) { for (quint64 id : list) { allIds << id; } @@ -527,9 +526,8 @@ auto map = postingDb.toTestMap(); - QList<PostingList> allLists = map.values(); QSet<quint64> allIds; - for (auto list : allLists) { + Q_FOREACH (const auto& list, map) { for (quint64 id : list) { allIds << id; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/src/file/fileindexerconfig.cpp new/baloo-5.28.0/src/file/fileindexerconfig.cpp --- old/baloo-5.27.0/src/file/fileindexerconfig.cpp 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/src/file/fileindexerconfig.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -286,7 +286,7 @@ // Add all removable media and network shares as ignored unless they have // been explicitly added in the include list - for (auto device: m_devices->allMedia()) { + for (const auto& device: m_devices->allMedia()) { const QString mountPath = device.mountPath(); if (!device.isUsable() && !mountPath.isEmpty()) { if (!includeFoldersPlain.contains(mountPath)) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/src/file/pendingfilequeue.cpp new/baloo-5.28.0/src/file/pendingfilequeue.cpp --- old/baloo-5.27.0/src/file/pendingfilequeue.cpp 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/src/file/pendingfilequeue.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -57,7 +57,6 @@ { // If we get an event to remove /home/A, remove all events for everything under /home/A/ if (file.shouldRemoveIndex() && file.path().endsWith('/')) { - const QString path = file.path(); QMutableVectorIterator<PendingFile> it(m_cache); while (it.hasNext()) { PendingFile pf = it.next(); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/baloo-5.27.0/tests/file/storagedevicestest.cpp new/baloo-5.28.0/tests/file/storagedevicestest.cpp --- old/baloo-5.27.0/tests/file/storagedevicestest.cpp 2016-10-02 11:42:18.000000000 +0200 +++ new/baloo-5.28.0/tests/file/storagedevicestest.cpp 2016-11-05 15:40:23.000000000 +0100 @@ -32,7 +32,7 @@ QCoreApplication app(argc, argv); StorageDevices sd; - for (auto device : sd.allMedia()) { + for (const auto& device : sd.allMedia()) { qDebug() << device.mountPath() << device.isUsable(); }
