summaryrefslogtreecommitdiffstats
path: root/tests/tst_qPrefDiveComputer.qml
diff options
context:
space:
mode:
authorGravatar jan Iversen <jani@apache.org>2018-09-07 13:53:00 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-09-11 17:25:00 -0700
commit1ee726597239db4e1fd66b5ad70983a127280414 (patch)
treec2f045b5c3acb385e2bd6d1625924e7e1f02cfce /tests/tst_qPrefDiveComputer.qml
parent684e334fb6098e604a91d140c1e2ea0883dff081 (diff)
downloadsubsurface-1ee726597239db4e1fd66b5ad70983a127280414.tar.gz
tests: update qml test cases
use new qml registration Signed-off-by: Jan Iversen <jani@apache.org>
Diffstat (limited to 'tests/tst_qPrefDiveComputer.qml')
-rw-r--r--tests/tst_qPrefDiveComputer.qml39
1 files changed, 15 insertions, 24 deletions
diff --git a/tests/tst_qPrefDiveComputer.qml b/tests/tst_qPrefDiveComputer.qml
index 4fe105f47..46ab96a2f 100644
--- a/tests/tst_qPrefDiveComputer.qml
+++ b/tests/tst_qPrefDiveComputer.qml
@@ -1,39 +1,30 @@
// SPDX-License-Identifier: GPL-2.0
import QtQuick 2.6
import QtTest 1.2
-import org.subsurfacedivelog.mobile 1.0
TestCase {
name: "qPrefDiveComputer"
- SsrfDiveComputerPrefs {
- id: tst
- }
-
- SsrfPrefs {
- id: prefs
- }
-
function test_variables() {
- var x1 = tst.device
- tst.device = "my device"
- compare(tst.device, "my device")
+ var x1 = PrefDiveComputer.device
+ PrefDiveComputer.device = "my device"
+ compare(PrefDiveComputer.device, "my device")
- var x1 = tst.device_name
- tst.device_name = "my device name"
- compare(tst.device_name, "my device name")
+ var x2 = PrefDiveComputer.device_name
+ PrefDiveComputer.device_name = "my device name"
+ compare(PrefDiveComputer.device_name, "my device name")
- var x1 = tst.download_mode
- tst.download_mode = 19
- compare(tst.download_mode, 19)
+ var x3 = PrefDiveComputer.download_mode
+ PrefDiveComputer.download_mode = 19
+ compare(PrefDiveComputer.download_mode, 19)
- var x1 = tst.product
- tst.product = "my product"
- compare(tst.product, "my product")
+ var x4 = PrefDiveComputer.product
+ PrefDiveComputer.product = "my product"
+ compare(PrefDiveComputer.product, "my product")
- var x1 = tst.vendor
- tst.vendor = "my vendor"
- compare(tst.vendor, "my vendor")
+ var x5 = PrefDiveComputer.vendor
+ PrefDiveComputer.vendor = "my vendor"
+ compare(PrefDiveComputer.vendor, "my vendor")
}
}