aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/qmlcppcodegen/data
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/qml/qmlcppcodegen/data')
-rw-r--r--tests/auto/qml/qmlcppcodegen/data/typedArray.qml9
-rw-r--r--tests/auto/qml/qmlcppcodegen/data/valueTypeLists.qml3
2 files changed, 12 insertions, 0 deletions
diff --git a/tests/auto/qml/qmlcppcodegen/data/typedArray.qml b/tests/auto/qml/qmlcppcodegen/data/typedArray.qml
index f9a40f5584..8d94d0832f 100644
--- a/tests/auto/qml/qmlcppcodegen/data/typedArray.qml
+++ b/tests/auto/qml/qmlcppcodegen/data/typedArray.qml
@@ -10,8 +10,17 @@ QtObject {
property list<date> values4: [aDate, aDate, aDate]
property list<real> values5: [1, 2, 3.4, "30", undefined, null]
property list<QtObject> values6: [self, self, self]
+ property string values7: "abcdef"
property int inIntList: values3[1]
property date inDateList: values4[2]
property real inRealList: values5[3]
+ property string inCharList: values7[5]
+
+ function stringAt10(s: string): int {
+ if (!s[10])
+ return 10;
+ else
+ return 20;
+ }
}
diff --git a/tests/auto/qml/qmlcppcodegen/data/valueTypeLists.qml b/tests/auto/qml/qmlcppcodegen/data/valueTypeLists.qml
index 83325641ab..cf58ae68c5 100644
--- a/tests/auto/qml/qmlcppcodegen/data/valueTypeLists.qml
+++ b/tests/auto/qml/qmlcppcodegen/data/valueTypeLists.qml
@@ -4,6 +4,7 @@ QtObject {
property list<rect> rectList: [ Qt.rect(1,2,3,4), Qt.rect(5,6,7,8), Qt.rect(9,10,11,12) ]
property list<string> stringList: ["aaa", "bbb", "ccc"]
property list<int> intList: [5, 6, 7, 8]
+ property string charList: "abcde"
property var rectInBounds: rectList[0]
property var rectOutOfBounds: rectList[32]
@@ -11,4 +12,6 @@ QtObject {
property var stringOutOfBounds: stringList[33]
property var intInBounds: intList[2]
property var intOutOfBounds: intList[34]
+ property var charInBounds: charList[3]
+ property var charOutOfBounds: charList[35]
}