File: test_AuthModel.qml

package info (click to toggle)
ausweisapp2 2.4.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 23,632 kB
  • sloc: cpp: 114,622; python: 2,833; xml: 1,426; java: 923; sh: 186; makefile: 7
file content (33 lines) | stat: -rw-r--r-- 855 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/**
 * Copyright (c) 2025-2026 Governikus GmbH & Co. KG, Germany
 */
import QtQuick
import QtTest

TestCase {
	id: testCase

	function createTestObject() {
		return createTemporaryQmlObject("
			import QtQuick
			import Governikus.Type

			Item {
				readonly property int testStatus: GlobalStatusCode.No_Error
				readonly property int modelStatus: AuthModel.statusCode
				readonly property string testStatusString: \"Error code: Unknown_Error\"
				readonly property string modelStatusString: AuthModel.statusCodeDisplayString
			}
		", testCase);
	}
	function test_load() {
		let testObject = createTestObject();
		verify(testObject, "Object loaded");
		verify(testObject.testStatus, testObject.modelStatus);
		verify(testObject.testStatusString, testObject.statusCodeDisplayString);
	}

	name: "test_AuthModelQml"
	visible: true
	when: windowShown
}