diff options
Diffstat (limited to 'tests/benchmarks/corelib/io/qiodevice')
-rw-r--r-- | tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt | 10 | ||||
-rw-r--r-- | tests/benchmarks/corelib/io/qiodevice/tst_bench_qiodevice.cpp (renamed from tests/benchmarks/corelib/io/qiodevice/main.cpp) | 42 |
2 files changed, 12 insertions, 40 deletions
diff --git a/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt b/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt index 3af6d4f214..133a9a1ac3 100644 --- a/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt +++ b/tests/benchmarks/corelib/io/qiodevice/CMakeLists.txt @@ -1,4 +1,5 @@ -# Generated from qiodevice.pro. +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause ##################################################################### ## tst_bench_qiodevice Binary: @@ -6,10 +7,7 @@ qt_internal_add_benchmark(tst_bench_qiodevice SOURCES - main.cpp - PUBLIC_LIBRARIES + tst_bench_qiodevice.cpp + LIBRARIES Qt::Test ) - -#### Keys ignored in scope 1:.:.:qiodevice.pro:<TRUE>: -# TEMPLATE = "app" diff --git a/tests/benchmarks/corelib/io/qiodevice/main.cpp b/tests/benchmarks/corelib/io/qiodevice/tst_bench_qiodevice.cpp index de4660a253..cae90631ee 100644 --- a/tests/benchmarks/corelib/io/qiodevice/main.cpp +++ b/tests/benchmarks/corelib/io/qiodevice/tst_bench_qiodevice.cpp @@ -1,30 +1,5 @@ -/**************************************************************************** -** -** Copyright (C) 2016 The Qt Company Ltd. -** Contact: https://www.qt.io/licensing/ -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:GPL-EXCEPT$ -** Commercial License Usage -** Licensees holding valid commercial Qt licenses may use this file in -** accordance with the commercial license agreement provided with the -** Software or, alternatively, in accordance with the terms contained in -** a written agreement between you and The Qt Company. For licensing terms -** and conditions see https://www.qt.io/terms-conditions. For further -** information use the contact form at https://www.qt.io/contact-us. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU -** General Public License version 3 as published by the Free Software -** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT -** included in the packaging of this file. Please review the following -** information to ensure the GNU General Public License requirements will -** be met: https://www.gnu.org/licenses/gpl-3.0.html. -** -** $QT_END_LICENSE$ -** -****************************************************************************/ +// Copyright (C) 2016 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only #include <QDebug> #include <QIODevice> #include <QFile> @@ -32,8 +7,7 @@ #include <qtest.h> - -class tst_qiodevice : public QObject +class tst_QIODevice : public QObject { Q_OBJECT private slots: @@ -48,7 +22,7 @@ private: }; -void tst_qiodevice::read_data() +void tst_QIODevice::read_data() { QTest::addColumn<qint64>("size"); QTest::newRow("10k") << qint64(10 * 1024); @@ -59,7 +33,7 @@ void tst_qiodevice::read_data() QTest::newRow("1000000k") << qint64(1000000 * 1024); } -void tst_qiodevice::read_old() +void tst_QIODevice::read_old() { QFETCH(qint64, size); @@ -88,7 +62,7 @@ void tst_qiodevice::read_old() } } -void tst_qiodevice::peekAndRead() +void tst_QIODevice::peekAndRead() { QFETCH(qint64, size); @@ -119,6 +93,6 @@ void tst_qiodevice::peekAndRead() } } -QTEST_MAIN(tst_qiodevice) +QTEST_MAIN(tst_QIODevice) -#include "main.moc" +#include "tst_bench_qiodevice.moc" |