summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/io
diff options
context:
space:
mode:
authorMÃ¥rten Nordheim <marten.nordheim@qt.io>2020-11-18 16:13:15 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2020-12-04 06:35:39 +0000
commitcfa83bbc15aa4a8e84a9fd628cbf0b9b61622b0c (patch)
treea106f6eec7c66984da4cdea7126e9b40f1883191 /tests/auto/corelib/io
parentba291add454f9ce8d1747492ceb08f373d6a92cc (diff)
tst_qstorageinfo: Test the copy ctor
It was previously untested Task-number: QTBUG-88183 Change-Id: Icc59fc632957a75cac8c7f5e2a1aed88a1c9ff9d Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit a7610a0cf79c576b098999822c5070a078e51326) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'tests/auto/corelib/io')
-rw-r--r--tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp b/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp
index 7dd76a2be1..ff89dc0f35 100644
--- a/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp
+++ b/tests/auto/corelib/io/qstorageinfo/tst_qstorageinfo.cpp
@@ -109,6 +109,13 @@ void tst_QStorageInfo::operatorEqual()
QStorageInfo storage2;
QCOMPARE(storage1, storage2);
}
+
+ // Test copy ctor
+ {
+ QStorageInfo storage1 = QStorageInfo::root();
+ QStorageInfo storage2(storage1);
+ QCOMPARE(storage1, storage2);
+ }
}
void tst_QStorageInfo::operatorNotEqual()