diff options
author | Warwick Allison <warwick.allison@nokia.com> | 2010-02-24 02:42:00 (GMT) |
---|---|---|
committer | Warwick Allison <warwick.allison@nokia.com> | 2010-02-24 02:42:00 (GMT) |
commit | 7c76abb0dc4204043bec9b6fa315f9753a7986ae (patch) | |
tree | cee303672cfd138790645e731f2d69472564d4b7 /tests/auto/declarative/qmllanguage | |
parent | 4066e60e859853cfe3240245ba05271e79839506 (diff) | |
download | Qt-7c76abb0dc4204043bec9b6fa315f9753a7986ae.zip Qt-7c76abb0dc4204043bec9b6fa315f9753a7986ae.tar.gz Qt-7c76abb0dc4204043bec9b6fa315f9753a7986ae.tar.bz2 |
Change class prefix to from QmlXXX to QDeclarativeXXX, QmlGraphicsXXX to QDeclarativeXXX.
Diffstat (limited to 'tests/auto/declarative/qmllanguage')
290 files changed, 0 insertions, 3300 deletions
diff --git a/tests/auto/declarative/qmllanguage/data/Alias.qml b/tests/auto/declarative/qmllanguage/data/Alias.qml deleted file mode 100644 index 55aa231..0000000 --- a/tests/auto/declarative/qmllanguage/data/Alias.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Qt 4.6 - -QtObject { - id: root - property int value: 1892 - property alias aliasValue: root.value -} - diff --git a/tests/auto/declarative/qmllanguage/data/Alias2.qml b/tests/auto/declarative/qmllanguage/data/Alias2.qml deleted file mode 100644 index 6362b2d..0000000 --- a/tests/auto/declarative/qmllanguage/data/Alias2.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - property var other - other: MyTypeObject { id: obj } - property alias enumAlias: obj.enumProperty; -} - diff --git a/tests/auto/declarative/qmllanguage/data/Alias3.qml b/tests/auto/declarative/qmllanguage/data/Alias3.qml deleted file mode 100644 index d1e78f8..0000000 --- a/tests/auto/declarative/qmllanguage/data/Alias3.qml +++ /dev/null @@ -1,12 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - property alias obj : otherObj - property var child - child: QtObject { - id: otherObj - property int myValue: 10 - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/Alias4.qml b/tests/auto/declarative/qmllanguage/data/Alias4.qml deleted file mode 100644 index 573674c..0000000 --- a/tests/auto/declarative/qmllanguage/data/Alias4.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -Alias3 {} - diff --git a/tests/auto/declarative/qmllanguage/data/ComponentComposite.qml b/tests/auto/declarative/qmllanguage/data/ComponentComposite.qml deleted file mode 100644 index 05fbc3f..0000000 --- a/tests/auto/declarative/qmllanguage/data/ComponentComposite.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -Component { - QtObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/CompositeType.qml b/tests/auto/declarative/qmllanguage/data/CompositeType.qml deleted file mode 100644 index 99d010f..0000000 --- a/tests/auto/declarative/qmllanguage/data/CompositeType.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Qt 4.6 - -QtObject { -} diff --git a/tests/auto/declarative/qmllanguage/data/CompositeType2.qml b/tests/auto/declarative/qmllanguage/data/CompositeType2.qml deleted file mode 100644 index 86210e9..0000000 --- a/tests/auto/declarative/qmllanguage/data/CompositeType2.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyQmlObject { -} - diff --git a/tests/auto/declarative/qmllanguage/data/CompositeType3.qml b/tests/auto/declarative/qmllanguage/data/CompositeType3.qml deleted file mode 100644 index d08f35b..0000000 --- a/tests/auto/declarative/qmllanguage/data/CompositeType3.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -QtObject { - property int a -} diff --git a/tests/auto/declarative/qmllanguage/data/CompositeType4.qml b/tests/auto/declarative/qmllanguage/data/CompositeType4.qml deleted file mode 100644 index a6a8168..0000000 --- a/tests/auto/declarative/qmllanguage/data/CompositeType4.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyQmlObject { - property int a -} - diff --git a/tests/auto/declarative/qmllanguage/data/DynamicPropertiesNestedType.qml b/tests/auto/declarative/qmllanguage/data/DynamicPropertiesNestedType.qml deleted file mode 100644 index aefbf9a..0000000 --- a/tests/auto/declarative/qmllanguage/data/DynamicPropertiesNestedType.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - property int super_a: 10 - property int super_c: 14 -} diff --git a/tests/auto/declarative/qmllanguage/data/HelperAlias.qml b/tests/auto/declarative/qmllanguage/data/HelperAlias.qml deleted file mode 100644 index dc3b382..0000000 --- a/tests/auto/declarative/qmllanguage/data/HelperAlias.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - property var child - child: QtObject { id: obj } - property alias objAlias: obj; -} - diff --git a/tests/auto/declarative/qmllanguage/data/I18n.qml b/tests/auto/declarative/qmllanguage/data/I18n.qml deleted file mode 100644 index 558c836..0000000 --- a/tests/auto/declarative/qmllanguage/data/I18n.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyTypeObject { - property int áâãäå: 10 - stringProperty: "Test áâãäå: " + áâãäå -} diff --git a/tests/auto/declarative/qmllanguage/data/I18nType30.qml b/tests/auto/declarative/qmllanguage/data/I18nType30.qml deleted file mode 100644 index 42dbc69..0000000 --- a/tests/auto/declarative/qmllanguage/data/I18nType30.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyTypeObject { - stringProperty: "Test áâãäå: 30" -} diff --git a/tests/auto/declarative/qmllanguage/data/MyComponent.qml b/tests/auto/declarative/qmllanguage/data/MyComponent.qml deleted file mode 100644 index 1a23277..0000000 --- a/tests/auto/declarative/qmllanguage/data/MyComponent.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyQmlObject { - property real x; - property real y; -} diff --git a/tests/auto/declarative/qmllanguage/data/MyCompositeValueSource.qml b/tests/auto/declarative/qmllanguage/data/MyCompositeValueSource.qml deleted file mode 100644 index e620e26..0000000 --- a/tests/auto/declarative/qmllanguage/data/MyCompositeValueSource.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyPropertyValueSource { - property int x -} - diff --git a/tests/auto/declarative/qmllanguage/data/MyContainerComponent.qml b/tests/auto/declarative/qmllanguage/data/MyContainerComponent.qml deleted file mode 100644 index 61f54c5..0000000 --- a/tests/auto/declarative/qmllanguage/data/MyContainerComponent.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyContainer { - property int x -} diff --git a/tests/auto/declarative/qmllanguage/data/NestedAlias.qml b/tests/auto/declarative/qmllanguage/data/NestedAlias.qml deleted file mode 100644 index 5155612..0000000 --- a/tests/auto/declarative/qmllanguage/data/NestedAlias.qml +++ /dev/null @@ -1,14 +0,0 @@ -import Qt 4.6 - -QtObject { - property QtObject o1 - property QtObject o2 - - property alias a: object2.a - - o1: QtObject { id: object1 } - o2: QtObject { - id: object2 - property int a: 1923 - } -} diff --git a/tests/auto/declarative/qmllanguage/data/NestedErrorsType.qml b/tests/auto/declarative/qmllanguage/data/NestedErrorsType.qml deleted file mode 100644 index 5cc8d20..0000000 --- a/tests/auto/declarative/qmllanguage/data/NestedErrorsType.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -Item { - x: "You can't assign a string to a real!" -} diff --git a/tests/auto/declarative/qmllanguage/data/OnCompletedType.qml b/tests/auto/declarative/qmllanguage/data/OnCompletedType.qml deleted file mode 100644 index 2889caf..0000000 --- a/tests/auto/declarative/qmllanguage/data/OnCompletedType.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -MyQmlObject { - property int a: Math.max(10, 9) - property int b: 11 - Component.onCompleted: console.log("Completed " + a + " " + b); -} diff --git a/tests/auto/declarative/qmllanguage/data/alias.1.qml b/tests/auto/declarative/qmllanguage/data/alias.1.qml deleted file mode 100644 index 500b0f6..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.1.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - id: root - property int value: 10 - property alias valueAlias: root.value -} diff --git a/tests/auto/declarative/qmllanguage/data/alias.2.qml b/tests/auto/declarative/qmllanguage/data/alias.2.qml deleted file mode 100644 index 5c92270..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.2.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 - -MyQmlObject { - id: root - property alias aliasObject: root.qmlobjectProperty - - qmlobjectProperty: MyQmlObject { value : 10 } -} diff --git a/tests/auto/declarative/qmllanguage/data/alias.3.qml b/tests/auto/declarative/qmllanguage/data/alias.3.qml deleted file mode 100644 index e059937..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.3.qml +++ /dev/null @@ -1,10 +0,0 @@ -import Qt 4.6 - -QtObject { - property var other - other: Alias { id: myAliasObject } - - property alias value: myAliasObject.aliasValue - property alias value2: myAliasObject.value -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.4.qml b/tests/auto/declarative/qmllanguage/data/alias.4.qml deleted file mode 100644 index bd6a769..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.4.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -Alias2 { - enumAlias: MyTypeObject.EnumVal2 -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.5.qml b/tests/auto/declarative/qmllanguage/data/alias.5.qml deleted file mode 100644 index 4316d0d..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.5.qml +++ /dev/null @@ -1,13 +0,0 @@ -import Qt 4.6 -import Test 1.0 - -QtObject { - property alias otherAlias: otherObject - - property var other - other: MyQmlObject { - id: otherObject - value: 10 - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.6.qml b/tests/auto/declarative/qmllanguage/data/alias.6.qml deleted file mode 100644 index e3af230..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.6.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Qt 4.6 - -QtObject { - property QtObject o; - property alias a: object.a - o: NestedAlias { id: object } -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.7.qml b/tests/auto/declarative/qmllanguage/data/alias.7.qml deleted file mode 100644 index a9a57eb..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.7.qml +++ /dev/null @@ -1,14 +0,0 @@ -import Qt 4.6 - -QtObject { - property QtObject object - property alias aliasedObject: target.object - - object: QtObject { - id: target - - property QtObject object - object: QtObject {} - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.8.qml b/tests/auto/declarative/qmllanguage/data/alias.8.qml deleted file mode 100644 index 2b9ad85..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.8.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -QtObject { - property var other - other: Alias3 { id: myAliasObject } - - property int value: myAliasObject.obj.myValue -} - diff --git a/tests/auto/declarative/qmllanguage/data/alias.9.qml b/tests/auto/declarative/qmllanguage/data/alias.9.qml deleted file mode 100644 index a2a41a1..0000000 --- a/tests/auto/declarative/qmllanguage/data/alias.9.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -QtObject { - property var other - other: Alias4 { id: myAliasObject } - - property int value: myAliasObject.obj.myValue -} - diff --git a/tests/auto/declarative/qmllanguage/data/assignBasicTypes.qml b/tests/auto/declarative/qmllanguage/data/assignBasicTypes.qml deleted file mode 100644 index c86c96b..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignBasicTypes.qml +++ /dev/null @@ -1,29 +0,0 @@ -import Test 1.0 -MyTypeObject { - flagProperty: "FlagVal1 | FlagVal3" - enumProperty: "EnumVal2" - stringProperty: "Hello World!" - uintProperty: 10 - intProperty: -19 - realProperty: 23.2 - doubleProperty: -19.7 - floatProperty: 8.5 - colorProperty: "red" - dateProperty: "1982-11-25" - timeProperty: "11:11:31" - timeProperty: "11:11:32" - timeProperty: "11:11:32" - dateTimeProperty: "2009-05-12T13:22:01" - pointProperty: "99,13" - pointFProperty: "-10.1,12.3" - sizeProperty: "99x13" - sizeFProperty: "0.1x0.2" - rectProperty: "9,7,100x200" - rectFProperty: "1000.1,-10.9,400x90.99" - boolProperty: true - variantProperty: "Hello World!" - vectorProperty: "10,1,2.2" - urlProperty: "main.qml" - - objectProperty: MyTypeObject { intProperty: 8 } -} diff --git a/tests/auto/declarative/qmllanguage/data/assignCompositeToType.qml b/tests/auto/declarative/qmllanguage/data/assignCompositeToType.qml deleted file mode 100644 index f6422bd..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignCompositeToType.qml +++ /dev/null @@ -1,18 +0,0 @@ -import Qt 4.6 -import Test 1.0 - -QtObject { - property QtObject myProperty - property QtObject myProperty2 - property QtObject myProperty3 - property QtObject myProperty4 - property MyQmlObject myProperty5 - property MyQmlObject myProperty6 - - myProperty: CompositeType {} - myProperty2: CompositeType2 {} - myProperty3: CompositeType3 {} - myProperty4: CompositeType4 {} - myProperty5: CompositeType2 {} - myProperty6: CompositeType4 {} -} diff --git a/tests/auto/declarative/qmllanguage/data/assignLiteralSignalProperty.qml b/tests/auto/declarative/qmllanguage/data/assignLiteralSignalProperty.qml deleted file mode 100644 index 399fcea..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignLiteralSignalProperty.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - onLiteralSignal: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/assignObjectToSignal.qml b/tests/auto/declarative/qmllanguage/data/assignObjectToSignal.qml deleted file mode 100644 index 789cc66..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignObjectToSignal.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - onBasicSignal: MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/assignObjectToVariant.qml b/tests/auto/declarative/qmllanguage/data/assignObjectToVariant.qml deleted file mode 100644 index 0ff9370..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignObjectToVariant.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - property var a; - a: MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/assignQmlComponent.qml b/tests/auto/declarative/qmllanguage/data/assignQmlComponent.qml deleted file mode 100644 index 20bdc55..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignQmlComponent.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyContainer { - MyComponent { x: 10; y: 11; } -} diff --git a/tests/auto/declarative/qmllanguage/data/assignSignal.qml b/tests/auto/declarative/qmllanguage/data/assignSignal.qml deleted file mode 100644 index 2a48df8..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignSignal.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyQmlObject { - onBasicSignal: basicSlot() - onBasicParameterizedSignal: basicSlotWithArgs(parameter) -} diff --git a/tests/auto/declarative/qmllanguage/data/assignTypeExtremes.qml b/tests/auto/declarative/qmllanguage/data/assignTypeExtremes.qml deleted file mode 100644 index 60ede52..0000000 --- a/tests/auto/declarative/qmllanguage/data/assignTypeExtremes.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - uintProperty: 4000000000 - intProperty: -2000000000 -} diff --git a/tests/auto/declarative/qmllanguage/data/attachedProperties.qml b/tests/auto/declarative/qmllanguage/data/attachedProperties.qml deleted file mode 100644 index b46ec34..0000000 --- a/tests/auto/declarative/qmllanguage/data/attachedProperties.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - MyQmlObject.value: 10 - Namespace.MyQmlObject.value2: 13 -} diff --git a/tests/auto/declarative/qmllanguage/data/autoComponentCreation.qml b/tests/auto/declarative/qmllanguage/data/autoComponentCreation.qml deleted file mode 100644 index 5d00144..0000000 --- a/tests/auto/declarative/qmllanguage/data/autoComponentCreation.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyTypeObject { - componentProperty : MyTypeObject { realProperty: 9 } -} diff --git a/tests/auto/declarative/qmllanguage/data/component.1.errors.txt b/tests/auto/declarative/qmllanguage/data/component.1.errors.txt deleted file mode 100644 index 091aad6..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:1:Cannot create empty component specification diff --git a/tests/auto/declarative/qmllanguage/data/component.1.qml b/tests/auto/declarative/qmllanguage/data/component.1.qml deleted file mode 100644 index 07e463a..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.1.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Qt 4.6 - -Component { -} diff --git a/tests/auto/declarative/qmllanguage/data/component.2.errors.txt b/tests/auto/declarative/qmllanguage/data/component.2.errors.txt deleted file mode 100644 index 76e7656..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -6:9:id is not unique diff --git a/tests/auto/declarative/qmllanguage/data/component.2.qml b/tests/auto/declarative/qmllanguage/data/component.2.qml deleted file mode 100644 index 88e0f73..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.2.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -Item { - id: myId - Component { - id: myId - QtObject {} - } -} diff --git a/tests/auto/declarative/qmllanguage/data/component.3.errors.txt b/tests/auto/declarative/qmllanguage/data/component.3.errors.txt deleted file mode 100644 index 9a13142..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -6:9:Invalid component id specification diff --git a/tests/auto/declarative/qmllanguage/data/component.3.qml b/tests/auto/declarative/qmllanguage/data/component.3.qml deleted file mode 100644 index 287a959..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.3.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -Item { - Component { - id: myId - id: myId2 - QtObject {} - } -} diff --git a/tests/auto/declarative/qmllanguage/data/component.4.errors.txt b/tests/auto/declarative/qmllanguage/data/component.4.errors.txt deleted file mode 100644 index 2ab18685..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:1:Invalid component body specification diff --git a/tests/auto/declarative/qmllanguage/data/component.4.qml b/tests/auto/declarative/qmllanguage/data/component.4.qml deleted file mode 100644 index ab1e29b..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.4.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -Component { - QtObject {} - QtObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/component.5.errors.txt b/tests/auto/declarative/qmllanguage/data/component.5.errors.txt deleted file mode 100644 index e3c2df7..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Component elements may not contain properties other than id diff --git a/tests/auto/declarative/qmllanguage/data/component.5.qml b/tests/auto/declarative/qmllanguage/data/component.5.qml deleted file mode 100644 index 629e998..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.5.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -Component { - x: 10 - QtObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/component.6.errors.txt b/tests/auto/declarative/qmllanguage/data/component.6.errors.txt deleted file mode 100644 index 2b1c6ca..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Invalid component id specification diff --git a/tests/auto/declarative/qmllanguage/data/component.6.qml b/tests/auto/declarative/qmllanguage/data/component.6.qml deleted file mode 100644 index 2303ebf..0000000 --- a/tests/auto/declarative/qmllanguage/data/component.6.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -Component { - id: QtObject {} - QtObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/componentCompositeType.qml b/tests/auto/declarative/qmllanguage/data/componentCompositeType.qml deleted file mode 100644 index 0a7249a..0000000 --- a/tests/auto/declarative/qmllanguage/data/componentCompositeType.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Qt 4.6 - -QtObject { - property var test - - test: ComponentComposite {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/cppnamespace.2.qml b/tests/auto/declarative/qmllanguage/data/cppnamespace.2.qml deleted file mode 100644 index e3b32ca..0000000 --- a/tests/auto/declarative/qmllanguage/data/cppnamespace.2.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MySecondNamespacedType { - list: [ MyNamespacedType {} ] -} diff --git a/tests/auto/declarative/qmllanguage/data/cppnamespace.qml b/tests/auto/declarative/qmllanguage/data/cppnamespace.qml deleted file mode 100644 index e1daf3b..0000000 --- a/tests/auto/declarative/qmllanguage/data/cppnamespace.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 - -MyNamespacedType { -} diff --git a/tests/auto/declarative/qmllanguage/data/crash2.qml b/tests/auto/declarative/qmllanguage/data/crash2.qml deleted file mode 100644 index a22c776..0000000 --- a/tests/auto/declarative/qmllanguage/data/crash2.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -QtObject { - objectName: "Hello" + "World" -} diff --git a/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.errors.txt b/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.errors.txt deleted file mode 100644 index 43a8bb2..0000000 --- a/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:19:ListElement: cannot use reserved "id" property diff --git a/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.qml b/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.qml deleted file mode 100644 index 00cc0c4..0000000 --- a/tests/auto/declarative/qmllanguage/data/customParserIdNotAllowed.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 -ListModel { - ListElement { a: 10 } - ListElement { id: foo; a: 12 } -} diff --git a/tests/auto/declarative/qmllanguage/data/customParserTypes.qml b/tests/auto/declarative/qmllanguage/data/customParserTypes.qml deleted file mode 100644 index cf2f272..0000000 --- a/tests/auto/declarative/qmllanguage/data/customParserTypes.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 -ListModel { - ListElement { a: 10 } - ListElement { a: 12 } -} diff --git a/tests/auto/declarative/qmllanguage/data/customVariantTypes.qml b/tests/auto/declarative/qmllanguage/data/customVariantTypes.qml deleted file mode 100644 index 0263ed2..0000000 --- a/tests/auto/declarative/qmllanguage/data/customVariantTypes.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - customType: "10" -} diff --git a/tests/auto/declarative/qmllanguage/data/declaredPropertyValues.qml b/tests/auto/declarative/qmllanguage/data/declaredPropertyValues.qml deleted file mode 100644 index 3987a3c..0000000 --- a/tests/auto/declarative/qmllanguage/data/declaredPropertyValues.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Qt 4.6 - -QtObject { - property int a: 10 - property int b: 10 + a - property QtObject c: QtObject {} - property list<QtObject> d: [ QtObject {}, QtObject {} ] -} diff --git a/tests/auto/declarative/qmllanguage/data/defaultGrouped.errors.txt b/tests/auto/declarative/qmllanguage/data/defaultGrouped.errors.txt deleted file mode 100644 index 945d51b..0000000 --- a/tests/auto/declarative/qmllanguage/data/defaultGrouped.errors.txt +++ /dev/null @@ -1 +0,0 @@ -7:9:Invalid value in grouped property diff --git a/tests/auto/declarative/qmllanguage/data/defaultGrouped.qml b/tests/auto/declarative/qmllanguage/data/defaultGrouped.qml deleted file mode 100644 index 0fd1404..0000000 --- a/tests/auto/declarative/qmllanguage/data/defaultGrouped.qml +++ /dev/null @@ -1,10 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -MyTypeObject { - grouped { - script: console.log(1921) - QtObject {} - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/defaultPropertyListOrder.qml b/tests/auto/declarative/qmllanguage/data/defaultPropertyListOrder.qml deleted file mode 100644 index 3651511..0000000 --- a/tests/auto/declarative/qmllanguage/data/defaultPropertyListOrder.qml +++ /dev/null @@ -1,29 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -MyContainer { - QtObject { - property int index: 0 - } - - QtObject { - property int index: 1 - } - - children: [ - QtObject { - property int index: 2 - }, - QtObject { - property int index: 3 - } - ] - - QtObject { - property int index: 4 - } - - QtObject { - property int index: 5 - } -} diff --git a/tests/auto/declarative/qmllanguage/data/doubleSignal.errors.txt b/tests/auto/declarative/qmllanguage/data/doubleSignal.errors.txt deleted file mode 100644 index 2aea251..0000000 --- a/tests/auto/declarative/qmllanguage/data/doubleSignal.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Incorrectly specified signal diff --git a/tests/auto/declarative/qmllanguage/data/doubleSignal.qml b/tests/auto/declarative/qmllanguage/data/doubleSignal.qml deleted file mode 100644 index fb07b9f..0000000 --- a/tests/auto/declarative/qmllanguage/data/doubleSignal.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 - -MyQmlObject { - onBasicSignal: console.log(1921) - onBasicSignal: console.log(1921) -} - diff --git a/tests/auto/declarative/qmllanguage/data/duplicateIDs.errors.txt b/tests/auto/declarative/qmllanguage/data/duplicateIDs.errors.txt deleted file mode 100644 index 66241cf..0000000 --- a/tests/auto/declarative/qmllanguage/data/duplicateIDs.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:19:id is not unique diff --git a/tests/auto/declarative/qmllanguage/data/duplicateIDs.qml b/tests/auto/declarative/qmllanguage/data/duplicateIDs.qml deleted file mode 100644 index a993abd..0000000 --- a/tests/auto/declarative/qmllanguage/data/duplicateIDs.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -MyContainer { - MyQmlObject { id: myID } - MyQmlObject { id: myID } -} - diff --git a/tests/auto/declarative/qmllanguage/data/dynamicObject.1.qml b/tests/auto/declarative/qmllanguage/data/dynamicObject.1.qml deleted file mode 100644 index 85d1052..0000000 --- a/tests/auto/declarative/qmllanguage/data/dynamicObject.1.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Qt 4.6 -PropertyChanges { - propa: a + 10 - propb: Math.min(a, 10) - propc: MyPropertyValueSource {} - onPropA: a -} diff --git a/tests/auto/declarative/qmllanguage/data/dynamicObjectProperties.qml b/tests/auto/declarative/qmllanguage/data/dynamicObjectProperties.qml deleted file mode 100644 index c80a7c0..0000000 --- a/tests/auto/declarative/qmllanguage/data/dynamicObjectProperties.qml +++ /dev/null @@ -1,13 +0,0 @@ -import Test 1.0 -import Qt 4.6 -import Qt 4.6 as Qt - -QtObject { - property QtObject objectProperty - property QtObject objectProperty2 - objectProperty2: QtObject {} - - property MyComponent myComponentProperty - property MyComponent myComponentProperty2 - myComponentProperty2: MyComponent {} -} diff --git a/tests/auto/declarative/qmllanguage/data/dynamicProperties.qml b/tests/auto/declarative/qmllanguage/data/dynamicProperties.qml deleted file mode 100644 index aef3269..0000000 --- a/tests/auto/declarative/qmllanguage/data/dynamicProperties.qml +++ /dev/null @@ -1,14 +0,0 @@ -import Test 1.0 -import Qt 4.6 -QtObject { - default property int intProperty : 10 - property bool boolProperty: false - property double doubleProperty: -10.1 - property real realProperty: -19.9 - property string stringProperty: "Hello World!" - property color colorProperty: "red" - property url urlProperty: "main.qml" - property date dateProperty: "1945-09-02" - property var varProperty: "Hello World!" - property variant variantProperty: 12 -} diff --git a/tests/auto/declarative/qmllanguage/data/dynamicPropertiesNested.qml b/tests/auto/declarative/qmllanguage/data/dynamicPropertiesNested.qml deleted file mode 100644 index 7bfab67..0000000 --- a/tests/auto/declarative/qmllanguage/data/dynamicPropertiesNested.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -DynamicPropertiesNestedType { - property int a: 13 - property int b: 12 - - super_a: 11 -} - diff --git a/tests/auto/declarative/qmllanguage/data/dynamicSignalsAndSlots.qml b/tests/auto/declarative/qmllanguage/data/dynamicSignalsAndSlots.qml deleted file mode 100644 index 2a834e8..0000000 --- a/tests/auto/declarative/qmllanguage/data/dynamicSignalsAndSlots.qml +++ /dev/null @@ -1,10 +0,0 @@ -import Qt 4.6 -QtObject { - signal signal1 - function slot1() {} - signal signal2 - function slot2() {} - - property int test: 0 - function slot3(a) { console.log(1921); test = a; } -} diff --git a/tests/auto/declarative/qmllanguage/data/empty.errors.txt b/tests/auto/declarative/qmllanguage/data/empty.errors.txt deleted file mode 100644 index d416e76..0000000 --- a/tests/auto/declarative/qmllanguage/data/empty.errors.txt +++ /dev/null @@ -1,2 +0,0 @@ -0:0:Expected token `numeric literal' -0:0:Expected a qualified name id diff --git a/tests/auto/declarative/qmllanguage/data/empty.qml b/tests/auto/declarative/qmllanguage/data/empty.qml deleted file mode 100644 index e69de29..0000000 --- a/tests/auto/declarative/qmllanguage/data/empty.qml +++ /dev/null diff --git a/tests/auto/declarative/qmllanguage/data/emptySignal.errors.txt b/tests/auto/declarative/qmllanguage/data/emptySignal.errors.txt deleted file mode 100644 index 353bbf5..0000000 --- a/tests/auto/declarative/qmllanguage/data/emptySignal.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Empty signal assignment diff --git a/tests/auto/declarative/qmllanguage/data/emptySignal.qml b/tests/auto/declarative/qmllanguage/data/emptySignal.qml deleted file mode 100644 index 4c5a122..0000000 --- a/tests/auto/declarative/qmllanguage/data/emptySignal.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyQmlObject { - onBasicSignal: " " -} - diff --git a/tests/auto/declarative/qmllanguage/data/failingComponent.errors.txt b/tests/auto/declarative/qmllanguage/data/failingComponent.errors.txt deleted file mode 100644 index 0cf0ef3..0000000 --- a/tests/auto/declarative/qmllanguage/data/failingComponent.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Type FailingComponent unavailable diff --git a/tests/auto/declarative/qmllanguage/data/failingComponentTest.qml b/tests/auto/declarative/qmllanguage/data/failingComponentTest.qml deleted file mode 100644 index 74a6acf..0000000 --- a/tests/auto/declarative/qmllanguage/data/failingComponentTest.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyContainer { - FailingComponent {} -} diff --git a/tests/auto/declarative/qmllanguage/data/fakeDotProperty.errors.txt b/tests/auto/declarative/qmllanguage/data/fakeDotProperty.errors.txt deleted file mode 100644 index 3074823..0000000 --- a/tests/auto/declarative/qmllanguage/data/fakeDotProperty.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Invalid grouped property access diff --git a/tests/auto/declarative/qmllanguage/data/fakeDotProperty.qml b/tests/auto/declarative/qmllanguage/data/fakeDotProperty.qml deleted file mode 100644 index d971eee..0000000 --- a/tests/auto/declarative/qmllanguage/data/fakeDotProperty.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - value.something: "hello" -} diff --git a/tests/auto/declarative/qmllanguage/data/finalOverride.errors.txt b/tests/auto/declarative/qmllanguage/data/finalOverride.errors.txt deleted file mode 100644 index 49e06cb..0000000 --- a/tests/auto/declarative/qmllanguage/data/finalOverride.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Cannot override FINAL property diff --git a/tests/auto/declarative/qmllanguage/data/finalOverride.qml b/tests/auto/declarative/qmllanguage/data/finalOverride.qml deleted file mode 100644 index a84393a..0000000 --- a/tests/auto/declarative/qmllanguage/data/finalOverride.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - property int value: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyNames.qml b/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyNames.qml deleted file mode 100644 index 558c836..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyNames.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyTypeObject { - property int áâãäå: 10 - stringProperty: "Test áâãäå: " + áâãäå -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyUse.qml b/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyUse.qml deleted file mode 100644 index 74918e2..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nDeclaredPropertyUse.qml +++ /dev/null @@ -1,3 +0,0 @@ -I18n { - áâãäå: 15 -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nNameSpace.qml b/tests/auto/declarative/qmllanguage/data/i18nNameSpace.qml deleted file mode 100644 index c0b2f94..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nNameSpace.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 as Áâãäå - -Áâãäå.MyTypeObject { - stringProperty: "Test áâãäå: 40" -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nScript.qml b/tests/auto/declarative/qmllanguage/data/i18nScript.qml deleted file mode 100644 index 942ed90..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nScript.qml +++ /dev/null @@ -1,12 +0,0 @@ -import Test 1.0 - -MyTypeObject { - Script { - function val() { - var áâãäå = 20 - return "Test áâãäå: " + áâãäå - } - - } - stringProperty: val() -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nStrings.qml b/tests/auto/declarative/qmllanguage/data/i18nStrings.qml deleted file mode 100644 index 764c926..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nStrings.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyTypeObject { - stringProperty: "Test áâãäå (5 accented 'a' letters)" -} diff --git a/tests/auto/declarative/qmllanguage/data/i18nType.qml b/tests/auto/declarative/qmllanguage/data/i18nType.qml deleted file mode 100644 index d7954ef..0000000 --- a/tests/auto/declarative/qmllanguage/data/i18nType.qml +++ /dev/null @@ -1 +0,0 @@ -I18nTypeÁâãäå { } diff --git a/tests/auto/declarative/qmllanguage/data/idProperty.qml b/tests/auto/declarative/qmllanguage/data/idProperty.qml deleted file mode 100644 index 90c1483..0000000 --- a/tests/auto/declarative/qmllanguage/data/idProperty.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -MyContainer { - property var object : myObjectId - - MyTypeObject { - id: "myObjectId" - } -} diff --git a/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.errors.txt b/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.errors.txt deleted file mode 100644 index 231998d..0000000 --- a/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:1:Namespace Rectangle cannot be used as a type diff --git a/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.qml b/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.qml deleted file mode 100644 index cd112af..0000000 --- a/tests/auto/declarative/qmllanguage/data/importNamespaceConflict.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 as Rectangle -import Qt 4.6 - -Rectangle { } diff --git a/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.errors.txt b/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.errors.txt deleted file mode 100644 index c7d880e..0000000 --- a/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.errors.txt +++ /dev/null @@ -1 +0,0 @@ -1:16:Library import requires a version diff --git a/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.qml b/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.qml deleted file mode 100644 index 23ed566..0000000 --- a/tests/auto/declarative/qmllanguage/data/importVersionMissingBuiltIn.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test as S - -S.MyQmlObject { - property real x; - property real y; -} - diff --git a/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.errors.txt b/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.errors.txt deleted file mode 100644 index 89e58ee..0000000 --- a/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.errors.txt +++ /dev/null @@ -1 +0,0 @@ -1:35:Library import requires a version diff --git a/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.qml b/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.qml deleted file mode 100644 index 97ec222..0000000 --- a/tests/auto/declarative/qmllanguage/data/importVersionMissingInstalled.qml +++ /dev/null @@ -1,3 +0,0 @@ -import com.nokia.installedtest as T - -T.InstalledTest {} diff --git a/tests/auto/declarative/qmllanguage/data/inlineQmlComponents.qml b/tests/auto/declarative/qmllanguage/data/inlineQmlComponents.qml deleted file mode 100644 index 478f06a..0000000 --- a/tests/auto/declarative/qmllanguage/data/inlineQmlComponents.qml +++ /dev/null @@ -1,10 +0,0 @@ -import Test 1.0 -import Qt 4.6 -MyContainer { - Component { - id: myComponent - MyQmlObject { - value: 11 - } - } -} diff --git a/tests/auto/declarative/qmllanguage/data/interfaceProperty.qml b/tests/auto/declarative/qmllanguage/data/interfaceProperty.qml deleted file mode 100644 index 70879ff..0000000 --- a/tests/auto/declarative/qmllanguage/data/interfaceProperty.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -import Qt 4.6 -MyQmlObject { - interfaceProperty: MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/interfaceQList.qml b/tests/auto/declarative/qmllanguage/data/interfaceQList.qml deleted file mode 100644 index c87dfae..0000000 --- a/tests/auto/declarative/qmllanguage/data/interfaceQList.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -MyContainer { - qlistInterfaces: [ - MyQmlObject {}, - MyQmlObject {} - ] -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.errors.txt deleted file mode 100644 index 492bbb4..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:17:Cannot assign to non-existent property "foo" diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.qml deleted file mode 100644 index 324f79c..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.1.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - MyQmlObject.foo: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.errors.txt deleted file mode 100644 index ff2409b..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:15:Non-existent attached object diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.qml deleted file mode 100644 index b768e9f..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.10.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - Namespace.MadeUpClass.foo: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.errors.txt deleted file mode 100644 index fee5050..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:15:Not an attached property name diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.qml deleted file mode 100644 index 7b782be..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.11.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - Namespace.madeUpClass.foo: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.errors.txt deleted file mode 100644 index 34de769..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:27:Cannot assign to non-existent property "foo" diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.qml deleted file mode 100644 index 1f47c61..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.2.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - Namespace.MyQmlObject.foo: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.errors.txt deleted file mode 100644 index 05161c4..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Invalid attached object assignment diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.qml deleted file mode 100644 index 79c2981..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.3.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - MyQmlObject: 10 -} - - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.errors.txt deleted file mode 100644 index a208bcf..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:15:Invalid attached object assignment diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.qml deleted file mode 100644 index af0be80..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.4.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - Namespace.MyQmlObject: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.errors.txt deleted file mode 100644 index 05161c4..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Invalid attached object assignment diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.qml deleted file mode 100644 index 0546322..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.5.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - MyQmlObject: QtObject {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.errors.txt deleted file mode 100644 index 6770e1f..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Non-existent attached object diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.qml deleted file mode 100644 index 108109a..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.6.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - Test.MyQmlObject: QtObject {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.errors.txt deleted file mode 100644 index 6770e1f..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Non-existent attached object diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.qml deleted file mode 100644 index ccf0353..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.7.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - MyTypeObject.foo: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.errors.txt deleted file mode 100644 index ff2409b..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:15:Non-existent attached object diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.qml deleted file mode 100644 index e736379..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.8.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 as Namespace -import Qt 4.6 - -QtObject { - Namespace.MyTypeObject.foo: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.errors.txt deleted file mode 100644 index 6770e1f..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Non-existent attached object diff --git a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.qml b/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.qml deleted file mode 100644 index a095229..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidAttachedProperty.9.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - MadeUpClass.foo: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt deleted file mode 100644 index 810fd31..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Invalid grouped property access diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml deleted file mode 100644 index 1167e39..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.1.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - property var o; - o.blah: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt deleted file mode 100644 index 810fd31..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:5:Invalid grouped property access diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml deleted file mode 100644 index a0c8306..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.2.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -QtObject { - property int o; - o.blah: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.errors.txt deleted file mode 100644 index f6d6f29..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Invalid grouped property access diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.qml deleted file mode 100644 index 0bbfc4f..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.3.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyQmlObject { - customType.x: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.errors.txt deleted file mode 100644 index 69c6871..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Cannot assign to non-existent property "foo" diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.qml deleted file mode 100644 index 134fef9..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.4.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyQmlObject { - foo.x: 10 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.errors.txt deleted file mode 100644 index 2c8a970..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:18:Property assignment expected diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.qml deleted file mode 100644 index 55cefe6..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.5.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyTypeObject { - rectProperty.x.foo: 100 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.errors.txt deleted file mode 100644 index 8331725..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:18:Single property assignment expected diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.qml deleted file mode 100644 index 9ec33ab..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.6.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyTypeObject { - rectProperty.x: 100 - rectProperty.x: 101 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.errors.txt deleted file mode 100644 index 4a7e383..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:-1:Cannot set properties on nullGrouped as it is null diff --git a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.qml b/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.qml deleted file mode 100644 index 977539a..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidGroupedProperty.7.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyTypeObject { - nullGrouped.script: console.log(1921) -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.2.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.2.errors.txt deleted file mode 100644 index 56e3eeb..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.2.errors.txt +++ /dev/null @@ -1,2 +0,0 @@ -3:5:"" is not a valid object id - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.2.qml b/tests/auto/declarative/qmllanguage/data/invalidID.2.qml deleted file mode 100644 index 4fb3b29..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.2.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyQmlObject { - id: "" -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.3.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.3.errors.txt deleted file mode 100644 index bb811cf..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Invalid use of id property diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.3.qml b/tests/auto/declarative/qmllanguage/data/invalidID.3.qml deleted file mode 100644 index 6684172..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.3.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyQmlObject { - id.other: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.4.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.4.errors.txt deleted file mode 100644 index cfe8756..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Invalid use of id property diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.4.qml b/tests/auto/declarative/qmllanguage/data/invalidID.4.qml deleted file mode 100644 index 86010bf..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.4.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -MyQmlObject { - id: hello - id: world -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.5.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.5.errors.txt deleted file mode 100644 index c167de3..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -2:20:Invalid import qualifier ID diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.5.qml b/tests/auto/declarative/qmllanguage/data/invalidID.5.qml deleted file mode 100644 index 5b92a1a..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.5.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -import Test 1.0 as hello -MyQmlObject { - id: hello -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.6.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.6.errors.txt deleted file mode 100644 index 160e8b5..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:"StartsWithUpperCase" is not a valid object id diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.6.qml b/tests/auto/declarative/qmllanguage/data/invalidID.6.qml deleted file mode 100644 index 62187d9..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.6.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyQmlObject { - id: StartsWithUpperCase -} - diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidID.errors.txt deleted file mode 100644 index 1ca678c..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:"1" is not a valid object id diff --git a/tests/auto/declarative/qmllanguage/data/invalidID.qml b/tests/auto/declarative/qmllanguage/data/invalidID.qml deleted file mode 100644 index 04db3eb..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidID.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - id: 1 -} diff --git a/tests/auto/declarative/qmllanguage/data/invalidImportID.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidImportID.errors.txt deleted file mode 100644 index a65f5fd..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidImportID.errors.txt +++ /dev/null @@ -1 +0,0 @@ -2:18:Invalid import qualifier ID diff --git a/tests/auto/declarative/qmllanguage/data/invalidImportID.qml b/tests/auto/declarative/qmllanguage/data/invalidImportID.qml deleted file mode 100644 index 30d88d5..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidImportID.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Qt 4.6 -import Qt 4.6 as qt - -QtObject {} diff --git a/tests/auto/declarative/qmllanguage/data/invalidRoot.errors.txt b/tests/auto/declarative/qmllanguage/data/invalidRoot.errors.txt deleted file mode 100644 index 4bcc948..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidRoot.errors.txt +++ /dev/null @@ -1 +0,0 @@ -1:1:Expected type name diff --git a/tests/auto/declarative/qmllanguage/data/invalidRoot.qml b/tests/auto/declarative/qmllanguage/data/invalidRoot.qml deleted file mode 100644 index 427827c..0000000 --- a/tests/auto/declarative/qmllanguage/data/invalidRoot.qml +++ /dev/null @@ -1,2 +0,0 @@ -foo { -} diff --git a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest.qml b/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest.qml deleted file mode 100644 index d8a22a8..0000000 --- a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Rectangle {} diff --git a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest2.qml b/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest2.qml deleted file mode 100644 index a0706ad..0000000 --- a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/InstalledTest2.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Text {} diff --git a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/PrivateType.qml b/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/PrivateType.qml deleted file mode 100644 index 93c7630..0000000 --- a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/PrivateType.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Image {} diff --git a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/qmldir b/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/qmldir deleted file mode 100644 index eeb9a05..0000000 --- a/tests/auto/declarative/qmllanguage/data/lib/com/nokia/installedtest/qmldir +++ /dev/null @@ -1,4 +0,0 @@ -Rectangle 1.5 InstalledTest2.qml -InstalledTest 1.4 InstalledTest2.qml -InstalledTest 1.0 InstalledTest.qml -InstalledTestTP 0.0 InstalledTest.qml diff --git a/tests/auto/declarative/qmllanguage/data/listAssignment.2.errors.txt b/tests/auto/declarative/qmllanguage/data/listAssignment.2.errors.txt deleted file mode 100644 index 8b40aa3..0000000 --- a/tests/auto/declarative/qmllanguage/data/listAssignment.2.errors.txt +++ /dev/null @@ -1,2 +0,0 @@ -3:15:Cannot assign primitives to lists - diff --git a/tests/auto/declarative/qmllanguage/data/listAssignment.2.qml b/tests/auto/declarative/qmllanguage/data/listAssignment.2.qml deleted file mode 100644 index e3baadb..0000000 --- a/tests/auto/declarative/qmllanguage/data/listAssignment.2.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyContainer { - children: 2 -} diff --git a/tests/auto/declarative/qmllanguage/data/listAssignment.3.errors.txt b/tests/auto/declarative/qmllanguage/data/listAssignment.3.errors.txt deleted file mode 100644 index 8c7b7e9..0000000 --- a/tests/auto/declarative/qmllanguage/data/listAssignment.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:15:Can only assign one binding to lists diff --git a/tests/auto/declarative/qmllanguage/data/listAssignment.3.qml b/tests/auto/declarative/qmllanguage/data/listAssignment.3.qml deleted file mode 100644 index 00c4c6b..0000000 --- a/tests/auto/declarative/qmllanguage/data/listAssignment.3.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -MyContainer { - children: childBinding.expression - children: childBinding2.expression -} - diff --git a/tests/auto/declarative/qmllanguage/data/listItemDeleteSelf.qml b/tests/auto/declarative/qmllanguage/data/listItemDeleteSelf.qml deleted file mode 100644 index 32b5b6c..0000000 --- a/tests/auto/declarative/qmllanguage/data/listItemDeleteSelf.qml +++ /dev/null @@ -1,38 +0,0 @@ -import Qt 4.6 - -Item { - ListModel { - id: fruitModel - ListElement { - name: "Apple" - cost: 2.45 - } - ListElement { - name: "Orange" - cost: 3.25 - } - ListElement { - name: "Banana" - cost: 1.95 - } - } - - Component { - id: fruitDelegate - Item { - width: 200; height: 50 - Text { text: name } - Text { text: '$'+cost; anchors.right: parent.right } - MouseArea { - anchors.fill: parent - onClicked: fruitModel.remove(index) - } - } - } - - ListView { - model: fruitModel - delegate: fruitDelegate - anchors.fill: parent - } -} diff --git a/tests/auto/declarative/qmllanguage/data/listProperties.qml b/tests/auto/declarative/qmllanguage/data/listProperties.qml deleted file mode 100644 index ba9e37c..0000000 --- a/tests/auto/declarative/qmllanguage/data/listProperties.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -QtObject { - property list<QtObject> listProperty - property int test: listProperty.length - - listProperty: [ QtObject{}, QtObject {} ] -} - diff --git a/tests/auto/declarative/qmllanguage/data/missingObject.errors.txt b/tests/auto/declarative/qmllanguage/data/missingObject.errors.txt deleted file mode 100644 index b31b562..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingObject.errors.txt +++ /dev/null @@ -1 +0,0 @@ -1:10:Expected token `{' diff --git a/tests/auto/declarative/qmllanguage/data/missingObject.qml b/tests/auto/declarative/qmllanguage/data/missingObject.qml deleted file mode 100644 index 2f17045..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingObject.qml +++ /dev/null @@ -1 +0,0 @@ -something: 24 diff --git a/tests/auto/declarative/qmllanguage/data/missingSignal.errors.txt b/tests/auto/declarative/qmllanguage/data/missingSignal.errors.txt deleted file mode 100644 index f562246..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingSignal.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Cannot assign to non-existent property "onClicked" diff --git a/tests/auto/declarative/qmllanguage/data/missingSignal.qml b/tests/auto/declarative/qmllanguage/data/missingSignal.qml deleted file mode 100644 index 3bf75f6..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingSignal.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -import Qt 4.6 -QtObject { - onClicked: console.log("Hello world!") -} diff --git a/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.errors.txt b/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.errors.txt deleted file mode 100644 index caf7e55..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:18:Cannot assign to non-existent property "foo" diff --git a/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.qml b/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.qml deleted file mode 100644 index 9a0fa6a..0000000 --- a/tests/auto/declarative/qmllanguage/data/missingValueTypeProperty.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 - -MyTypeObject { - rectProperty.foo: 9 -} diff --git a/tests/auto/declarative/qmllanguage/data/nestedErrors.errors.txt b/tests/auto/declarative/qmllanguage/data/nestedErrors.errors.txt deleted file mode 100644 index 886da55..0000000 --- a/tests/auto/declarative/qmllanguage/data/nestedErrors.errors.txt +++ /dev/null @@ -1,2 +0,0 @@ -4:5:Unable to create type NestedErrorsType -4:8:Invalid property assignment: double expected diff --git a/tests/auto/declarative/qmllanguage/data/nestedErrors.qml b/tests/auto/declarative/qmllanguage/data/nestedErrors.qml deleted file mode 100644 index c0d755a..0000000 --- a/tests/auto/declarative/qmllanguage/data/nestedErrors.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -Item { - NestedErrorsType {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.errors.txt deleted file mode 100644 index 6bfce9a..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -2:15:Cannot assign to non-existent property "something" diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.qml deleted file mode 100644 index df7406c..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.1.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Test 1.0 -MyQmlObject { something: 24 } diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.errors.txt deleted file mode 100644 index 4b30056..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Cannot assign to non-existent property "something" diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.qml deleted file mode 100644 index 06ccd37..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.2.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - something: 24 -} diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.errors.txt deleted file mode 100644 index 4b30056..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Cannot assign to non-existent property "something" diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.qml deleted file mode 100644 index 5b08608..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.3.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - something: 1 + 1 -} diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.errors.txt deleted file mode 100644 index 4b30056..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Cannot assign to non-existent property "something" diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.qml deleted file mode 100644 index 6579191..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.4.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - something: ; -} diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.errors.txt deleted file mode 100644 index c07f2b9..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Expected a qualified name id diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.qml deleted file mode 100644 index 37af057..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.5.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - 24 -} diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.errors.txt b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.errors.txt deleted file mode 100644 index 89925b7..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Cannot assign to non-existent default property diff --git a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.qml b/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.qml deleted file mode 100644 index 5cd55d0..0000000 --- a/tests/auto/declarative/qmllanguage/data/nonexistantProperty.6.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/nullDotProperty.errors.txt b/tests/auto/declarative/qmllanguage/data/nullDotProperty.errors.txt deleted file mode 100644 index 07a4094..0000000 --- a/tests/auto/declarative/qmllanguage/data/nullDotProperty.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:-1:Cannot set properties on obj as it is null diff --git a/tests/auto/declarative/qmllanguage/data/nullDotProperty.qml b/tests/auto/declarative/qmllanguage/data/nullDotProperty.qml deleted file mode 100644 index 4e36779..0000000 --- a/tests/auto/declarative/qmllanguage/data/nullDotProperty.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyDotPropertyObject { - obj.value: 1 -} diff --git a/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.errors.txt b/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.errors.txt deleted file mode 100644 index db7d9c0..0000000 --- a/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:18:Unexpected object assignment diff --git a/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.qml b/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.qml deleted file mode 100644 index 9924773..0000000 --- a/tests/auto/declarative/qmllanguage/data/objectValueTypeProperty.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyTypeObject { - rectProperty.x: MyTypeObject {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/onCompleted.qml b/tests/auto/declarative/qmllanguage/data/onCompleted.qml deleted file mode 100644 index 5725f85..0000000 --- a/tests/auto/declarative/qmllanguage/data/onCompleted.qml +++ /dev/null @@ -1,17 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -MyTypeObject { - // We set a and b to ensure that onCompleted is executed after bindings and - // constants have been assigned - property int a: Math.min(6, 7) - Component.onCompleted: console.log("Completed " + a + " " + nestedObject.b) - - objectProperty: OnCompletedType { - qmlobjectProperty: MyQmlObject { - id: nestedObject - property int b: 10 - Component.onCompleted: console.log("Completed " + a + " " + nestedObject.b) - } - } -} diff --git a/tests/auto/declarative/qmllanguage/data/property.1.errors.txt b/tests/auto/declarative/qmllanguage/data/property.1.errors.txt deleted file mode 100644 index 3ae6c46..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:14:Expected property type diff --git a/tests/auto/declarative/qmllanguage/data/property.1.qml b/tests/auto/declarative/qmllanguage/data/property.1.qml deleted file mode 100644 index cadc39a..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.1.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -QtObject { - property blah a; -} diff --git a/tests/auto/declarative/qmllanguage/data/property.2.errors.txt b/tests/auto/declarative/qmllanguage/data/property.2.errors.txt deleted file mode 100644 index a18e21a..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:14:Unexpected property type modifier diff --git a/tests/auto/declarative/qmllanguage/data/property.2.qml b/tests/auto/declarative/qmllanguage/data/property.2.qml deleted file mode 100644 index e810c6c..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.2.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - property invalidmodifier<int> a; -} - diff --git a/tests/auto/declarative/qmllanguage/data/property.3.errors.txt b/tests/auto/declarative/qmllanguage/data/property.3.errors.txt deleted file mode 100644 index 5e09a25..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:14:Invalid property type modifier diff --git a/tests/auto/declarative/qmllanguage/data/property.3.qml b/tests/auto/declarative/qmllanguage/data/property.3.qml deleted file mode 100644 index 04147c2..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.3.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -QtObject { - property invalidmodifier<QtObject> a; -} - - diff --git a/tests/auto/declarative/qmllanguage/data/property.4.errors.txt b/tests/auto/declarative/qmllanguage/data/property.4.errors.txt deleted file mode 100644 index b447186..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:1:Syntax error diff --git a/tests/auto/declarative/qmllanguage/data/property.4.qml b/tests/auto/declarative/qmllanguage/data/property.4.qml deleted file mode 100644 index b2ec482..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.4.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -QtObject { - readonly property int a -} diff --git a/tests/auto/declarative/qmllanguage/data/property.5.errors.txt b/tests/auto/declarative/qmllanguage/data/property.5.errors.txt deleted file mode 100644 index 32a8dc1..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:Readonly not yet supported diff --git a/tests/auto/declarative/qmllanguage/data/property.5.qml b/tests/auto/declarative/qmllanguage/data/property.5.qml deleted file mode 100644 index 65fafbb..0000000 --- a/tests/auto/declarative/qmllanguage/data/property.5.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - readonly property int a: value -} - diff --git a/tests/auto/declarative/qmllanguage/data/propertyValueSource.2.qml b/tests/auto/declarative/qmllanguage/data/propertyValueSource.2.qml deleted file mode 100644 index 57a6070..0000000 --- a/tests/auto/declarative/qmllanguage/data/propertyValueSource.2.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - intProperty : MyCompositeValueSource {} -} - diff --git a/tests/auto/declarative/qmllanguage/data/propertyValueSource.qml b/tests/auto/declarative/qmllanguage/data/propertyValueSource.qml deleted file mode 100644 index ad71fcf..0000000 --- a/tests/auto/declarative/qmllanguage/data/propertyValueSource.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyTypeObject { - intProperty : MyPropertyValueSource {} -} diff --git a/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.1.qml b/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.1.qml deleted file mode 100644 index 429c327..0000000 --- a/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.1.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -import Qt 4.6 -QtObject { -} - diff --git a/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.2.qml b/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.2.qml deleted file mode 100644 index 0f57b61..0000000 --- a/tests/auto/declarative/qmllanguage/data/qmlAttachedPropertiesObjectMethod.2.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -import Qt 4.6 -QtObject { - MyQmlObject.value: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.1.errors.txt b/tests/auto/declarative/qmllanguage/data/readOnly.1.errors.txt deleted file mode 100644 index b8c3404..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:21:Invalid property assignment: "readOnlyString" is a read-only property diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.1.qml b/tests/auto/declarative/qmllanguage/data/readOnly.1.qml deleted file mode 100644 index 60757bd..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.1.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - readOnlyString: "Hello World" -} diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.2.errors.txt b/tests/auto/declarative/qmllanguage/data/readOnly.2.errors.txt deleted file mode 100644 index d857a04..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:5:Invalid property assignment: "readOnlyString" is a read-only property diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.2.qml b/tests/auto/declarative/qmllanguage/data/readOnly.2.qml deleted file mode 100644 index 8f1633c..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.2.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - readOnlyString: "Hello" + "World" -} diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.3.errors.txt b/tests/auto/declarative/qmllanguage/data/readOnly.3.errors.txt deleted file mode 100644 index c7e9e1b..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -6:36:Invalid property assignment: "objAlias" is a read-only property diff --git a/tests/auto/declarative/qmllanguage/data/readOnly.3.qml b/tests/auto/declarative/qmllanguage/data/readOnly.3.qml deleted file mode 100644 index cd86a48..0000000 --- a/tests/auto/declarative/qmllanguage/data/readOnly.3.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Test 1.0 -import Qt 4.6 - -QtObject { - property var child - child: HelperAlias { objAlias: QtObject {} } -} - diff --git a/tests/auto/declarative/qmllanguage/data/rootAsQmlComponent.qml b/tests/auto/declarative/qmllanguage/data/rootAsQmlComponent.qml deleted file mode 100644 index 8d72cd3..0000000 --- a/tests/auto/declarative/qmllanguage/data/rootAsQmlComponent.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 -MyContainerComponent { - x: 11 - MyQmlObject {} - MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/script.1.errors.txt b/tests/auto/declarative/qmllanguage/data/script.1.errors.txt deleted file mode 100644 index 50518cc..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:1:Invalid use of Script block diff --git a/tests/auto/declarative/qmllanguage/data/script.1.qml b/tests/auto/declarative/qmllanguage/data/script.1.qml deleted file mode 100644 index 8dac8b7..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.1.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Qt 4.6 - -Script { -} diff --git a/tests/auto/declarative/qmllanguage/data/script.10.errors.txt b/tests/auto/declarative/qmllanguage/data/script.10.errors.txt deleted file mode 100644 index 13f47d1..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.10.errors.txt +++ /dev/null @@ -1 +0,0 @@ -6:9:Component elements may not contain script blocks diff --git a/tests/auto/declarative/qmllanguage/data/script.10.qml b/tests/auto/declarative/qmllanguage/data/script.10.qml deleted file mode 100644 index 516e878..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.10.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -Item { - Component { - Item {} - Script {} - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/script.11.errors.txt b/tests/auto/declarative/qmllanguage/data/script.11.errors.txt deleted file mode 100644 index a664203..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.11.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Invalid Script block diff --git a/tests/auto/declarative/qmllanguage/data/script.11.qml b/tests/auto/declarative/qmllanguage/data/script.11.qml deleted file mode 100644 index 6d2d598..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.11.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - QtObject {} - } -} diff --git a/tests/auto/declarative/qmllanguage/data/script.12.errors.txt b/tests/auto/declarative/qmllanguage/data/script.12.errors.txt deleted file mode 100644 index 85c8396..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.12.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:5:QmlJS declaration outside Script element diff --git a/tests/auto/declarative/qmllanguage/data/script.12.qml b/tests/auto/declarative/qmllanguage/data/script.12.qml deleted file mode 100644 index 9ecb5d9..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.12.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - var a -} - diff --git a/tests/auto/declarative/qmllanguage/data/script.2.errors.txt b/tests/auto/declarative/qmllanguage/data/script.2.errors.txt deleted file mode 100644 index 8fb3bbd..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Properties cannot be set on Script block diff --git a/tests/auto/declarative/qmllanguage/data/script.2.qml b/tests/auto/declarative/qmllanguage/data/script.2.qml deleted file mode 100644 index dce1a41..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.2.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - id: myScript - } -} diff --git a/tests/auto/declarative/qmllanguage/data/script.3.errors.txt b/tests/auto/declarative/qmllanguage/data/script.3.errors.txt deleted file mode 100644 index 8fb3bbd..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Properties cannot be set on Script block diff --git a/tests/auto/declarative/qmllanguage/data/script.3.qml b/tests/auto/declarative/qmllanguage/data/script.3.qml deleted file mode 100644 index 8621a9a..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.3.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - hello: world - } -} diff --git a/tests/auto/declarative/qmllanguage/data/script.4.errors.txt b/tests/auto/declarative/qmllanguage/data/script.4.errors.txt deleted file mode 100644 index 49a507f..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Invalid Script source value diff --git a/tests/auto/declarative/qmllanguage/data/script.4.qml b/tests/auto/declarative/qmllanguage/data/script.4.qml deleted file mode 100644 index d89817c..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.4.qml +++ /dev/null @@ -1,8 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - source: 10 - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/script.5.errors.txt b/tests/auto/declarative/qmllanguage/data/script.5.errors.txt deleted file mode 100644 index 49a507f..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Invalid Script source value diff --git a/tests/auto/declarative/qmllanguage/data/script.5.qml b/tests/auto/declarative/qmllanguage/data/script.5.qml deleted file mode 100644 index 8986b3b..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.5.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - source: "hello" + ".js" - } -} - - diff --git a/tests/auto/declarative/qmllanguage/data/script.6.errors.txt b/tests/auto/declarative/qmllanguage/data/script.6.errors.txt deleted file mode 100644 index 4e53b6b..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Invalid Script block. Specify either the source property or inline script diff --git a/tests/auto/declarative/qmllanguage/data/script.6.qml b/tests/auto/declarative/qmllanguage/data/script.6.qml deleted file mode 100644 index 07e9d78..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.6.qml +++ /dev/null @@ -1,11 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - source: "test.js" - function helloWorld() {} - } -} - - - diff --git a/tests/auto/declarative/qmllanguage/data/script.7.errors.txt b/tests/auto/declarative/qmllanguage/data/script.7.errors.txt deleted file mode 100644 index dc15ddf..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.7.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Variable declarations not allow in inline Script blocks diff --git a/tests/auto/declarative/qmllanguage/data/script.7.qml b/tests/auto/declarative/qmllanguage/data/script.7.qml deleted file mode 100644 index fa905e6..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.7.qml +++ /dev/null @@ -1,11 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - var a = 10; - } -} - - - - diff --git a/tests/auto/declarative/qmllanguage/data/script.8.errors.txt b/tests/auto/declarative/qmllanguage/data/script.8.errors.txt deleted file mode 100644 index b5bf1a8..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.8.errors.txt +++ /dev/null @@ -1 +0,0 @@ -6:9:Invalid Script source value diff --git a/tests/auto/declarative/qmllanguage/data/script.8.qml b/tests/auto/declarative/qmllanguage/data/script.8.qml deleted file mode 100644 index f600c88..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.8.qml +++ /dev/null @@ -1,9 +0,0 @@ -import Qt 4.6 - -QtObject { - Script { - source: "test.js" - source: "test2.js" - } -} - diff --git a/tests/auto/declarative/qmllanguage/data/script.9.errors.txt b/tests/auto/declarative/qmllanguage/data/script.9.errors.txt deleted file mode 100644 index 41e8d46..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.9.errors.txt +++ /dev/null @@ -1 +0,0 @@ -5:9:Component elements may not contain script blocks diff --git a/tests/auto/declarative/qmllanguage/data/script.9.qml b/tests/auto/declarative/qmllanguage/data/script.9.qml deleted file mode 100644 index 79aa504..0000000 --- a/tests/auto/declarative/qmllanguage/data/script.9.qml +++ /dev/null @@ -1,7 +0,0 @@ -import Qt 4.6 - -Item { - Component { - Script {} - } -} diff --git a/tests/auto/declarative/qmllanguage/data/scriptString.qml b/tests/auto/declarative/qmllanguage/data/scriptString.qml deleted file mode 100644 index 40a3bbe..0000000 --- a/tests/auto/declarative/qmllanguage/data/scriptString.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Test 1.0 - -MyTypeObject { - scriptProperty: foo + bar - grouped.script: console.log(1921) -} diff --git a/tests/auto/declarative/qmllanguage/data/signal.1.errors.txt b/tests/auto/declarative/qmllanguage/data/signal.1.errors.txt deleted file mode 100644 index 78d9960..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:12:Expected parameter type diff --git a/tests/auto/declarative/qmllanguage/data/signal.1.qml b/tests/auto/declarative/qmllanguage/data/signal.1.qml deleted file mode 100644 index fbaf017..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.1.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Qt 4.6 - -QtObject { - signal mySignal(nontype a) -} diff --git a/tests/auto/declarative/qmllanguage/data/signal.2.errors.txt b/tests/auto/declarative/qmllanguage/data/signal.2.errors.txt deleted file mode 100644 index fce8928..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:21:Unexpected token `;' diff --git a/tests/auto/declarative/qmllanguage/data/signal.2.qml b/tests/auto/declarative/qmllanguage/data/signal.2.qml deleted file mode 100644 index 5049192..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.2.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - signal mySignal(,) -} - diff --git a/tests/auto/declarative/qmllanguage/data/signal.3.errors.txt b/tests/auto/declarative/qmllanguage/data/signal.3.errors.txt deleted file mode 100644 index bf043ac..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -4:22:Expected token `identifier' diff --git a/tests/auto/declarative/qmllanguage/data/signal.3.qml b/tests/auto/declarative/qmllanguage/data/signal.3.qml deleted file mode 100644 index 9dd4cc7..0000000 --- a/tests/auto/declarative/qmllanguage/data/signal.3.qml +++ /dev/null @@ -1,6 +0,0 @@ -import Qt 4.6 - -QtObject { - signal mySignal(a) -} - diff --git a/tests/auto/declarative/qmllanguage/data/simpleBindings.qml b/tests/auto/declarative/qmllanguage/data/simpleBindings.qml deleted file mode 100644 index 2fcd1a5..0000000 --- a/tests/auto/declarative/qmllanguage/data/simpleBindings.qml +++ /dev/null @@ -1,18 +0,0 @@ -import Test 1.0 -MyTypeObject { - id: me - property int v1: 10 - property int v2: 11 - - property int value1 - property int value2 - property int value3 - property int value4 - - value1: v1 - value2: me.v1 - value3: v1 + v2 - value4: Math.min(v1, v2) - - objectProperty: me -} diff --git a/tests/auto/declarative/qmllanguage/data/simpleContainer.qml b/tests/auto/declarative/qmllanguage/data/simpleContainer.qml deleted file mode 100644 index c3a795f..0000000 --- a/tests/auto/declarative/qmllanguage/data/simpleContainer.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyContainer { - MyQmlObject {} - MyQmlObject {} -} diff --git a/tests/auto/declarative/qmllanguage/data/simpleObject.qml b/tests/auto/declarative/qmllanguage/data/simpleObject.qml deleted file mode 100644 index 30c7823..0000000 --- a/tests/auto/declarative/qmllanguage/data/simpleObject.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Test 1.0 -MyQmlObject {} diff --git a/tests/auto/declarative/qmllanguage/data/subdir/Test.qml b/tests/auto/declarative/qmllanguage/data/subdir/Test.qml deleted file mode 100644 index c4d5905..0000000 --- a/tests/auto/declarative/qmllanguage/data/subdir/Test.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Rectangle { } diff --git a/tests/auto/declarative/qmllanguage/data/subdir/subsubdir/SubTest.qml b/tests/auto/declarative/qmllanguage/data/subdir/subsubdir/SubTest.qml deleted file mode 100644 index c4d5905..0000000 --- a/tests/auto/declarative/qmllanguage/data/subdir/subsubdir/SubTest.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Rectangle { } diff --git a/tests/auto/declarative/qmllanguage/data/test.js b/tests/auto/declarative/qmllanguage/data/test.js deleted file mode 100644 index e69de29..0000000 --- a/tests/auto/declarative/qmllanguage/data/test.js +++ /dev/null diff --git a/tests/auto/declarative/qmllanguage/data/test2.js b/tests/auto/declarative/qmllanguage/data/test2.js deleted file mode 100644 index e69de29..0000000 --- a/tests/auto/declarative/qmllanguage/data/test2.js +++ /dev/null diff --git a/tests/auto/declarative/qmllanguage/data/unregisteredObject.errors.txt b/tests/auto/declarative/qmllanguage/data/unregisteredObject.errors.txt deleted file mode 100644 index 347db05..0000000 --- a/tests/auto/declarative/qmllanguage/data/unregisteredObject.errors.txt +++ /dev/null @@ -1 +0,0 @@ -2:1:Type UnregisteredObjectType unavailable diff --git a/tests/auto/declarative/qmllanguage/data/unregisteredObject.qml b/tests/auto/declarative/qmllanguage/data/unregisteredObject.qml deleted file mode 100644 index 4969f62..0000000 --- a/tests/auto/declarative/qmllanguage/data/unregisteredObject.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Test 1.0 -UnregisteredObjectType {} diff --git a/tests/auto/declarative/qmllanguage/data/unsupportedProperty.errors.txt b/tests/auto/declarative/qmllanguage/data/unsupportedProperty.errors.txt deleted file mode 100644 index 3cd626d..0000000 --- a/tests/auto/declarative/qmllanguage/data/unsupportedProperty.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:13:Invalid property assignment: unsupported type "QMatrix" diff --git a/tests/auto/declarative/qmllanguage/data/unsupportedProperty.qml b/tests/auto/declarative/qmllanguage/data/unsupportedProperty.qml deleted file mode 100644 index 9f19680..0000000 --- a/tests/auto/declarative/qmllanguage/data/unsupportedProperty.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - matrix: "1,0,0,0,1,0,0,0,1" -} diff --git a/tests/auto/declarative/qmllanguage/data/valueTypes.qml b/tests/auto/declarative/qmllanguage/data/valueTypes.qml deleted file mode 100644 index bf325a7..0000000 --- a/tests/auto/declarative/qmllanguage/data/valueTypes.qml +++ /dev/null @@ -1,13 +0,0 @@ -import Test 1.0 -MyTypeObject { - rectProperty.x: 10 - rectProperty.y: 11 - rectProperty.width: rectProperty.x + 2 - rectProperty.height: 13 - - intProperty: rectProperty.x - - onAction: { var a = rectProperty; a.x = 12; } - - rectProperty2: rectProperty -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.1.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.1.errors.txt deleted file mode 100644 index ba7a076..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.1.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:12:Invalid property assignment: int expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.1.qml b/tests/auto/declarative/qmllanguage/data/wrongType.1.qml deleted file mode 100644 index 289d37f..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.1.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - value: "hello" -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.10.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.10.errors.txt deleted file mode 100644 index ae75b52..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.10.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:23:Invalid property assignment: datetime expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.10.qml b/tests/auto/declarative/qmllanguage/data/wrongType.10.qml deleted file mode 100644 index 2cf0e50..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.10.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - dateTimeProperty: 12 -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.11.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.11.errors.txt deleted file mode 100644 index 23a4cda..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.11.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:20:Invalid property assignment: point expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.11.qml b/tests/auto/declarative/qmllanguage/data/wrongType.11.qml deleted file mode 100644 index ae77ba1..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.11.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - pointProperty: "apples" -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.12.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.12.errors.txt deleted file mode 100644 index 3092100..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.12.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: size expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.12.qml b/tests/auto/declarative/qmllanguage/data/wrongType.12.qml deleted file mode 100644 index b7a366f..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.12.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - sizeProperty: "red" -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.13.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.13.errors.txt deleted file mode 100644 index ba7a076..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.13.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:12:Invalid property assignment: int expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.13.qml b/tests/auto/declarative/qmllanguage/data/wrongType.13.qml deleted file mode 100644 index 477aff1..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.13.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - value: "12" -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.14.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.14.errors.txt deleted file mode 100644 index d621fdd..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.14.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:21:Invalid property assignment: string expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.14.qml b/tests/auto/declarative/qmllanguage/data/wrongType.14.qml deleted file mode 100644 index 672d693..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.14.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - stringProperty: 10 -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.15.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.15.errors.txt deleted file mode 100644 index 44768e3..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.15.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:18:Invalid property assignment: url expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.15.qml b/tests/auto/declarative/qmllanguage/data/wrongType.15.qml deleted file mode 100644 index 633a5ba..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.15.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyTypeObject { - urlProperty: 12 -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.2.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.2.errors.txt deleted file mode 100644 index 9ff9f25..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.2.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:14:Invalid property assignment: boolean expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.2.qml b/tests/auto/declarative/qmllanguage/data/wrongType.2.qml deleted file mode 100644 index 34b74f7..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.2.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - enabled: 5 -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.3.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.3.errors.txt deleted file mode 100644 index 6d971c6..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.3.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:11:Invalid property assignment: rect expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.3.qml b/tests/auto/declarative/qmllanguage/data/wrongType.3.qml deleted file mode 100644 index 384181a..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.3.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyQmlObject { - rect: "5,5x10" -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.4.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.4.errors.txt deleted file mode 100644 index ef34d0e..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.4.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: unknown enumeration diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.4.qml b/tests/auto/declarative/qmllanguage/data/wrongType.4.qml deleted file mode 100644 index 0787bf5..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.4.qml +++ /dev/null @@ -1,4 +0,0 @@ -import Test 1.0 -MyTypeObject { - enumProperty: "InvalidEnumName" -} diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.5.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.5.errors.txt deleted file mode 100644 index cab10bd..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.5.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: unsigned int expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.5.qml b/tests/auto/declarative/qmllanguage/data/wrongType.5.qml deleted file mode 100644 index c50ae9a..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.5.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - uintProperty: -13 -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.6.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.6.errors.txt deleted file mode 100644 index d0a0b00..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.6.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: double expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.6.qml b/tests/auto/declarative/qmllanguage/data/wrongType.6.qml deleted file mode 100644 index da10b78..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.6.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - realProperty: "Hello" -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.7.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.7.errors.txt deleted file mode 100644 index 614346b..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.7.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:20:Invalid property assignment: color expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.7.qml b/tests/auto/declarative/qmllanguage/data/wrongType.7.qml deleted file mode 100644 index ddc3835..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.7.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - colorProperty: 12 -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.8.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.8.errors.txt deleted file mode 100644 index 1773c00..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.8.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: date expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.8.qml b/tests/auto/declarative/qmllanguage/data/wrongType.8.qml deleted file mode 100644 index a5f6756..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.8.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - dateProperty: 12 -} - diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.9.errors.txt b/tests/auto/declarative/qmllanguage/data/wrongType.9.errors.txt deleted file mode 100644 index 8630975..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.9.errors.txt +++ /dev/null @@ -1 +0,0 @@ -3:19:Invalid property assignment: time expected diff --git a/tests/auto/declarative/qmllanguage/data/wrongType.9.qml b/tests/auto/declarative/qmllanguage/data/wrongType.9.qml deleted file mode 100644 index a3db732..0000000 --- a/tests/auto/declarative/qmllanguage/data/wrongType.9.qml +++ /dev/null @@ -1,5 +0,0 @@ -import Test 1.0 -MyTypeObject { - timeProperty: 12 -} - diff --git a/tests/auto/declarative/qmllanguage/qmllanguage.pro b/tests/auto/declarative/qmllanguage/qmllanguage.pro deleted file mode 100644 index d1876ef..0000000 --- a/tests/auto/declarative/qmllanguage/qmllanguage.pro +++ /dev/null @@ -1,14 +0,0 @@ -load(qttest_p4) -contains(QT_CONFIG,declarative): QT += declarative -QT += script network -macx:CONFIG -= app_bundle - -SOURCES += tst_qmllanguage.cpp \ - testtypes.cpp -HEADERS += testtypes.h - -INCLUDEPATH += ../shared/ -HEADERS += ../shared/testhttpserver.h -SOURCES += ../shared/testhttpserver.cpp - -DEFINES += SRCDIR=\\\"$$PWD\\\" diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/LocalInternal.qml b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/LocalInternal.qml deleted file mode 100644 index 836c20a..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/LocalInternal.qml +++ /dev/null @@ -1,3 +0,0 @@ -import Qt 4.6 - -Image { source: "pics/blue.png" } diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/Test.qml b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/Test.qml deleted file mode 100644 index c4d5905..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/Test.qml +++ /dev/null @@ -1,2 +0,0 @@ -import Qt 4.6 -Rectangle { } diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestLocal.qml b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestLocal.qml deleted file mode 100644 index 11443ca..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestLocal.qml +++ /dev/null @@ -1 +0,0 @@ -LocalInternal {} diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestSubDir.qml b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestSubDir.qml deleted file mode 100644 index 0dfede4..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/TestSubDir.qml +++ /dev/null @@ -1,2 +0,0 @@ -import "subdir" -SubTest { } diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/pics/blue.png b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/pics/blue.png Binary files differdeleted file mode 100644 index 46f815f..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/pics/blue.png +++ /dev/null diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/qmldir b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/qmldir deleted file mode 100644 index b32f82b..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/qmldir +++ /dev/null @@ -1,3 +0,0 @@ -Test 0.0 Test.qml -TestSubDir 0.0 TestSubDir.qml -TestLocal 0.0 TestLocal.qml diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/SubTest.qml b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/SubTest.qml deleted file mode 100644 index 0ea9ec6..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/SubTest.qml +++ /dev/null @@ -1,3 +0,0 @@ -import Qt 4.6 - -Text {} diff --git a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/qmldir b/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/qmldir deleted file mode 100644 index f7016c7..0000000 --- a/tests/auto/declarative/qmllanguage/qtest/declarative/qmllanguage/subdir/qmldir +++ /dev/null @@ -1 +0,0 @@ -SubTest 0.0 SubTest.qml diff --git a/tests/auto/declarative/qmllanguage/testtypes.cpp b/tests/auto/declarative/qmllanguage/testtypes.cpp deleted file mode 100644 index 9ffe28a..0000000 --- a/tests/auto/declarative/qmllanguage/testtypes.cpp +++ /dev/null @@ -1,62 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the Technology Preview License Agreement accompanying -** this package. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** If you have questions regarding the use of this file, please contact -** Nokia at qt-info@nokia.com. -** -** -** -** -** -** -** -** -** $QT_END_LICENSE$ -** -****************************************************************************/ -#include "testtypes.h" - -void registerTypes() -{ - QML_REGISTER_INTERFACE(MyInterface); - QML_REGISTER_TYPE(Test,1,0,MyQmlObject,MyQmlObject); - QML_REGISTER_TYPE(Test,1,0,MyTypeObject,MyTypeObject); - QML_REGISTER_TYPE(Test,1,0,MyContainer,MyContainer); - QML_REGISTER_TYPE(Test,1,0,MyPropertyValueSource,MyPropertyValueSource); - QML_REGISTER_TYPE(Test,1,0,MyDotPropertyObject,MyDotPropertyObject); - QML_REGISTER_TYPE(Test,1,0,MyNamespacedType,MyNamespace::MyNamespacedType); - QML_REGISTER_TYPE(Test,1,0,MySecondNamespacedType,MyNamespace::MySecondNamespacedType); - QML_REGISTER_NOCREATE_TYPE(MyGroupedObject); -} - -QVariant myCustomVariantTypeConverter(const QString &data) -{ - MyCustomVariantType rv; - rv.a = data.toInt(); - return QVariant::fromValue(rv); -} - diff --git a/tests/auto/declarative/qmllanguage/testtypes.h b/tests/auto/declarative/qmllanguage/testtypes.h deleted file mode 100644 index 9fd0973..0000000 --- a/tests/auto/declarative/qmllanguage/testtypes.h +++ /dev/null @@ -1,547 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the Technology Preview License Agreement accompanying -** this package. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** If you have questions regarding the use of this file, please contact -** Nokia at qt-info@nokia.com. -** -** -** -** -** -** -** -** -** $QT_END_LICENSE$ -** -****************************************************************************/ -#ifndef TESTTYPES_H -#define TESTTYPES_H - -#include <QtCore/qobject.h> -#include <QtCore/qrect.h> -#include <QtCore/qdatetime.h> -#include <QtGui/qmatrix.h> -#include <QtGui/qcolor.h> -#include <QtGui/qvector3d.h> -#include <QtDeclarative/qml.h> -#include <QtDeclarative/qmlcomponent.h> -#include <QtDeclarative/qmlparserstatus.h> -#include <QtDeclarative/qmlpropertyvaluesource.h> -#include <QtDeclarative/qmlscriptstring.h> - -QVariant myCustomVariantTypeConverter(const QString &data); - -class MyInterface -{ -public: - MyInterface() : id(913) {} - int id; -}; -Q_DECLARE_INTERFACE(MyInterface, "com.trolltech.Qt.Test.MyInterface"); -QML_DECLARE_INTERFACE(MyInterface); - -struct MyCustomVariantType -{ - MyCustomVariantType() : a(0) {} - int a; -}; -Q_DECLARE_METATYPE(MyCustomVariantType); - -class MyAttachedObject : public QObject -{ - Q_OBJECT - Q_PROPERTY(int value READ value WRITE setValue) - Q_PROPERTY(int value2 READ value2 WRITE setValue2) -public: - MyAttachedObject(QObject *parent) : QObject(parent), m_value(0), m_value2(0) {} - - int value() const { return m_value; } - void setValue(int v) { m_value = v; } - - int value2() const { return m_value2; } - void setValue2(int v) { m_value2 = v; } - -private: - int m_value; - int m_value2; -}; - -class MyQmlObject : public QObject, public MyInterface, public QmlParserStatus -{ - Q_OBJECT - Q_PROPERTY(int value READ value WRITE setValue FINAL) - Q_PROPERTY(QString readOnlyString READ readOnlyString) - Q_PROPERTY(bool enabled READ enabled WRITE setEnabled) - Q_PROPERTY(QRect rect READ rect WRITE setRect) - Q_PROPERTY(QMatrix matrix READ matrix WRITE setMatrix) //assumed to be unsupported by QML - Q_PROPERTY(MyInterface *interfaceProperty READ interface WRITE setInterface) - Q_PROPERTY(int onLiteralSignal READ onLiteralSignal WRITE setOnLiteralSignal); - Q_PROPERTY(MyCustomVariantType customType READ customType WRITE setCustomType); - Q_PROPERTY(MyQmlObject *qmlobjectProperty READ qmlobject WRITE setQmlobject) - - Q_INTERFACES(MyInterface QmlParserStatus) -public: - MyQmlObject() : m_value(-1), m_interface(0), m_qmlobject(0) { qRegisterMetaType<MyCustomVariantType>("MyCustomVariantType"); } - - int value() const { return m_value; } - void setValue(int v) { m_value = v; } - - QString readOnlyString() const { return QLatin1String(""); } - - bool enabled() const { return false; } - void setEnabled(bool) {} - - QRect rect() const { return QRect(); } - void setRect(const QRect&) {} - - QMatrix matrix() const { return QMatrix(); } - void setMatrix(const QMatrix&) {} - - MyInterface *interface() const { return m_interface; } - void setInterface(MyInterface *iface) { m_interface = iface; } - - static MyAttachedObject *qmlAttachedProperties(QObject *other) { - return new MyAttachedObject(other); - } - Q_CLASSINFO("DefaultMethod", "basicSlot()"); - - int onLiteralSignal() const { return m_value; } - void setOnLiteralSignal(int v) { m_value = v; } - - MyQmlObject *qmlobject() const { return m_qmlobject; } - void setQmlobject(MyQmlObject *o) { m_qmlobject = o; } - - MyCustomVariantType customType() const { return m_custom; } - void setCustomType(const MyCustomVariantType &v) { m_custom = v; } -public slots: - void basicSlot() { qWarning("MyQmlObject::basicSlot"); } - void basicSlotWithArgs(int v) { qWarning("MyQmlObject::basicSlotWithArgs(%d)", v); } - -signals: - void basicSignal(); - void basicParameterizedSignal(int parameter); - -private: - friend class tst_qmllanguage; - int m_value; - MyInterface *m_interface; - MyQmlObject *m_qmlobject; - MyCustomVariantType m_custom; -}; -QML_DECLARE_TYPEINFO(MyQmlObject, QML_HAS_ATTACHED_PROPERTIES) -QML_DECLARE_TYPE(MyQmlObject); - -class MyGroupedObject : public QObject -{ - Q_OBJECT - Q_PROPERTY(QmlScriptString script READ script WRITE setScript); -public: - QmlScriptString script() const { return m_script; } - void setScript(const QmlScriptString &s) { m_script = s; } - -private: - QmlScriptString m_script; -}; - -QML_DECLARE_TYPE(MyGroupedObject); - - -class MyTypeObject : public QObject -{ - Q_OBJECT - Q_ENUMS(MyEnum) - Q_FLAGS(MyFlags) - - Q_PROPERTY(QString id READ id WRITE setId); - Q_PROPERTY(QObject *objectProperty READ objectProperty WRITE setObjectProperty); - Q_PROPERTY(QmlComponent *componentProperty READ componentProperty WRITE setComponentProperty); - Q_PROPERTY(MyFlags flagProperty READ flagProperty WRITE setFlagProperty); - Q_PROPERTY(MyEnum enumProperty READ enumProperty WRITE setEnumProperty); - Q_PROPERTY(QString stringProperty READ stringProperty WRITE setStringProperty); - Q_PROPERTY(uint uintProperty READ uintProperty WRITE setUintProperty); - Q_PROPERTY(int intProperty READ intProperty WRITE setIntProperty); - Q_PROPERTY(qreal realProperty READ realProperty WRITE setRealProperty); - Q_PROPERTY(double doubleProperty READ doubleProperty WRITE setDoubleProperty); - Q_PROPERTY(float floatProperty READ floatProperty WRITE setFloatProperty); - Q_PROPERTY(QColor colorProperty READ colorProperty WRITE setColorProperty); - Q_PROPERTY(QDate dateProperty READ dateProperty WRITE setDateProperty); - Q_PROPERTY(QTime timeProperty READ timeProperty WRITE setTimeProperty); - Q_PROPERTY(QDateTime dateTimeProperty READ dateTimeProperty WRITE setDateTimeProperty); - Q_PROPERTY(QPoint pointProperty READ pointProperty WRITE setPointProperty); - Q_PROPERTY(QPointF pointFProperty READ pointFProperty WRITE setPointFProperty); - Q_PROPERTY(QSize sizeProperty READ sizeProperty WRITE setSizeProperty); - Q_PROPERTY(QSizeF sizeFProperty READ sizeFProperty WRITE setSizeFProperty); - Q_PROPERTY(QRect rectProperty READ rectProperty WRITE setRectProperty NOTIFY rectPropertyChanged); - Q_PROPERTY(QRect rectProperty2 READ rectProperty2 WRITE setRectProperty2); - Q_PROPERTY(QRectF rectFProperty READ rectFProperty WRITE setRectFProperty); - Q_PROPERTY(bool boolProperty READ boolProperty WRITE setBoolProperty); - Q_PROPERTY(QVariant variantProperty READ variantProperty WRITE setVariantProperty); - Q_PROPERTY(QVector3D vectorProperty READ vectorProperty WRITE setVectorProperty); - Q_PROPERTY(QUrl urlProperty READ urlProperty WRITE setUrlProperty); - - Q_PROPERTY(QmlScriptString scriptProperty READ scriptProperty WRITE setScriptProperty); - Q_PROPERTY(MyGroupedObject *grouped READ grouped CONSTANT); - Q_PROPERTY(MyGroupedObject *nullGrouped READ nullGrouped CONSTANT); - -public: - MyTypeObject() - : objectPropertyValue(0), componentPropertyValue(0) {} - - QString idValue; - QString id() const { - return idValue; - } - void setId(const QString &v) { - idValue = v; - } - - QObject *objectPropertyValue; - QObject *objectProperty() const { - return objectPropertyValue; - } - void setObjectProperty(QObject *v) { - objectPropertyValue = v; - } - - QmlComponent *componentPropertyValue; - QmlComponent *componentProperty() const { - return componentPropertyValue; - } - void setComponentProperty(QmlComponent *v) { - componentPropertyValue = v; - } - - enum MyFlag { FlagVal1 = 0x01, FlagVal2 = 0x02, FlagVal3 = 0x04 }; - Q_DECLARE_FLAGS(MyFlags, MyFlag) - MyFlags flagPropertyValue; - MyFlags flagProperty() const { - return flagPropertyValue; - } - void setFlagProperty(MyFlags v) { - flagPropertyValue = v; - } - - enum MyEnum { EnumVal1, EnumVal2 }; - MyEnum enumPropertyValue; - MyEnum enumProperty() const { - return enumPropertyValue; - } - void setEnumProperty(MyEnum v) { - enumPropertyValue = v; - } - - QString stringPropertyValue; - QString stringProperty() const { - return stringPropertyValue; - } - void setStringProperty(const QString &v) { - stringPropertyValue = v; - } - - uint uintPropertyValue; - uint uintProperty() const { - return uintPropertyValue; - } - void setUintProperty(const uint &v) { - uintPropertyValue = v; - } - - int intPropertyValue; - int intProperty() const { - return intPropertyValue; - } - void setIntProperty(const int &v) { - intPropertyValue = v; - } - - qreal realPropertyValue; - qreal realProperty() const { - return realPropertyValue; - } - void setRealProperty(const qreal &v) { - realPropertyValue = v; - } - - double doublePropertyValue; - double doubleProperty() const { - return doublePropertyValue; - } - void setDoubleProperty(const double &v) { - doublePropertyValue = v; - } - - float floatPropertyValue; - float floatProperty() const { - return floatPropertyValue; - } - void setFloatProperty(const float &v) { - floatPropertyValue = v; - } - - QColor colorPropertyValue; - QColor colorProperty() const { - return colorPropertyValue; - } - void setColorProperty(const QColor &v) { - colorPropertyValue = v; - } - - QDate datePropertyValue; - QDate dateProperty() const { - return datePropertyValue; - } - void setDateProperty(const QDate &v) { - datePropertyValue = v; - } - - QTime timePropertyValue; - QTime timeProperty() const { - return timePropertyValue; - } - void setTimeProperty(const QTime &v) { - timePropertyValue = v; - } - - QDateTime dateTimePropertyValue; - QDateTime dateTimeProperty() const { - return dateTimePropertyValue; - } - void setDateTimeProperty(const QDateTime &v) { - dateTimePropertyValue = v; - } - - QPoint pointPropertyValue; - QPoint pointProperty() const { - return pointPropertyValue; - } - void setPointProperty(const QPoint &v) { - pointPropertyValue = v; - } - - QPointF pointFPropertyValue; - QPointF pointFProperty() const { - return pointFPropertyValue; - } - void setPointFProperty(const QPointF &v) { - pointFPropertyValue = v; - } - - QSize sizePropertyValue; - QSize sizeProperty() const { - return sizePropertyValue; - } - void setSizeProperty(const QSize &v) { - sizePropertyValue = v; - } - - QSizeF sizeFPropertyValue; - QSizeF sizeFProperty() const { - return sizeFPropertyValue; - } - void setSizeFProperty(const QSizeF &v) { - sizeFPropertyValue = v; - } - - QRect rectPropertyValue; - QRect rectProperty() const { - return rectPropertyValue; - } - void setRectProperty(const QRect &v) { - rectPropertyValue = v; - emit rectPropertyChanged(); - } - - QRect rectPropertyValue2; - QRect rectProperty2() const { - return rectPropertyValue2; - } - void setRectProperty2(const QRect &v) { - rectPropertyValue2 = v; - } - - QRectF rectFPropertyValue; - QRectF rectFProperty() const { - return rectFPropertyValue; - } - void setRectFProperty(const QRectF &v) { - rectFPropertyValue = v; - } - - bool boolPropertyValue; - bool boolProperty() const { - return boolPropertyValue; - } - void setBoolProperty(const bool &v) { - boolPropertyValue = v; - } - - QVariant variantPropertyValue; - QVariant variantProperty() const { - return variantPropertyValue; - } - void setVariantProperty(const QVariant &v) { - variantPropertyValue = v; - } - - QVector3D vectorPropertyValue; - QVector3D vectorProperty() const { - return vectorPropertyValue; - } - void setVectorProperty(const QVector3D &v) { - vectorPropertyValue = v; - } - - QUrl urlPropertyValue; - QUrl urlProperty() const { - return urlPropertyValue; - } - void setUrlProperty(const QUrl &v) { - urlPropertyValue = v; - } - - QmlScriptString scriptPropertyValue; - QmlScriptString scriptProperty() const { - return scriptPropertyValue; - } - void setScriptProperty(const QmlScriptString &v) { - scriptPropertyValue = v; - } - - MyGroupedObject groupedValue; - MyGroupedObject *grouped() { return &groupedValue; } - - MyGroupedObject *nullGrouped() { return 0; } - - void doAction() { emit action(); } -signals: - void action(); - void rectPropertyChanged(); -}; -Q_DECLARE_OPERATORS_FOR_FLAGS(MyTypeObject::MyFlags) -QML_DECLARE_TYPE(MyTypeObject); - -class MyContainer : public QObject -{ - Q_OBJECT - Q_PROPERTY(QmlListProperty<QObject> children READ children) - Q_PROPERTY(QmlListProperty<MyInterface> qlistInterfaces READ qlistInterfaces) - Q_CLASSINFO("DefaultProperty", "children"); -public: - MyContainer() {} - - QmlListProperty<QObject> children() { return QmlListProperty<QObject>(this, m_children); } - QList<QObject *> *getChildren() { return &m_children; } - QmlListProperty<MyInterface> qlistInterfaces() { return QmlListProperty<MyInterface>(this, m_interfaces); } - QList<MyInterface *> *getQListInterfaces() { return &m_interfaces; } - - QList<QObject*> m_children; - QList<MyInterface *> m_interfaces; -}; - -QML_DECLARE_TYPE(MyContainer); - - -class MyPropertyValueSource : public QObject, public QmlPropertyValueSource -{ - Q_OBJECT - Q_INTERFACES(QmlPropertyValueSource) -public: - MyPropertyValueSource() - : QmlPropertyValueSource() {} - - QmlMetaProperty prop; - virtual void setTarget(const QmlMetaProperty &p) - { - prop = p; - } -}; -QML_DECLARE_TYPE(MyPropertyValueSource); - -class MyDotPropertyObject : public QObject -{ - Q_OBJECT - Q_PROPERTY(MyQmlObject *obj READ obj) - Q_PROPERTY(MyQmlObject *readWriteObj READ readWriteObj WRITE setReadWriteObj) -public: - MyDotPropertyObject() : m_rwobj(0), m_ownRWObj(false) {} - ~MyDotPropertyObject() - { - if (m_ownRWObj) - delete m_rwobj; - } - - MyQmlObject *obj() { return 0; } - - MyQmlObject *readWriteObj() - { - if (!m_rwobj) { - m_rwobj = new MyQmlObject; - m_ownRWObj = true; - } - return m_rwobj; - } - - void setReadWriteObj(MyQmlObject *obj) - { - if (m_ownRWObj) { - delete m_rwobj; - m_ownRWObj = false; - } - - m_rwobj = obj; - } - -private: - MyQmlObject *m_rwobj; - bool m_ownRWObj; -}; - -QML_DECLARE_TYPE(MyDotPropertyObject); - -namespace MyNamespace { - class MyNamespacedType : public QObject - { - Q_OBJECT - }; - - class MySecondNamespacedType : public QObject - { - Q_OBJECT - Q_PROPERTY(QmlListProperty<MyNamespace::MyNamespacedType> list READ list); - public: - QmlListProperty<MyNamespacedType> list() { return QmlListProperty<MyNamespacedType>(this, m_list); } - - private: - QList<MyNamespacedType *> m_list; - }; -} -QML_DECLARE_TYPE(MyNamespace::MyNamespacedType); -QML_DECLARE_TYPE(MyNamespace::MySecondNamespacedType); - -void registerTypes(); - -#endif // TESTTYPES_H diff --git a/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp b/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp deleted file mode 100644 index ecdd33a..0000000 --- a/tests/auto/declarative/qmllanguage/tst_qmllanguage.cpp +++ /dev/null @@ -1,1385 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of the test suite of the Qt Toolkit. -** -** $QT_BEGIN_LICENSE:LGPL$ -** No Commercial Usage -** This file contains pre-release code and may not be distributed. -** You may use this file in accordance with the terms and conditions -** contained in the Technology Preview License Agreement accompanying -** this package. -** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 as published by the Free Software -** Foundation and appearing in the file LICENSE.LGPL included in the -** packaging of this file. Please review the following information to -** ensure the GNU Lesser General Public License version 2.1 requirements -** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** If you have questions regarding the use of this file, please contact -** Nokia at qt-info@nokia.com. -** -** -** -** -** -** -** -** -** $QT_END_LICENSE$ -** -****************************************************************************/ -#include <qtest.h> -#include <QtDeclarative/qmlengine.h> -#include <QtDeclarative/qmlcomponent.h> -#include <QtCore/qfile.h> -#include <QtCore/qdebug.h> -#include <QtCore/qfileinfo.h> -#include <QtCore/qdir.h> -#include <private/qmlmetaproperty_p.h> -#include "testtypes.h" - -#include "../../../shared/util.h" - -/* -This test case covers QML language issues. This covers everything that does not -involve evaluating ECMAScript expressions and bindings. - -Evaluation of expressions and bindings is covered in qmlecmascript -*/ -class tst_qmllanguage : public QObject -{ - Q_OBJECT -public: - tst_qmllanguage() { - QmlMetaType::registerCustomStringConverter(qMetaTypeId<MyCustomVariantType>(), myCustomVariantTypeConverter); - QFileInfo fileInfo(__FILE__); - engine.addImportPath(fileInfo.absoluteDir().filePath(QLatin1String("data/lib"))); - } - -private slots: - void initTestCase(); - void cleanupTestCase(); - - void errors_data(); - void errors(); - - void simpleObject(); - void simpleContainer(); - void interfaceProperty(); - void interfaceQList(); - void assignObjectToSignal(); - void assignObjectToVariant(); - void assignLiteralSignalProperty(); - void assignQmlComponent(); - void assignBasicTypes(); - void assignTypeExtremes(); - void assignCompositeToType(); - void customParserTypes(); - void rootAsQmlComponent(); - void inlineQmlComponents(); - void idProperty(); - void assignSignal(); - void dynamicProperties(); - void dynamicPropertiesNested(); - void listProperties(); - void dynamicObjectProperties(); - void dynamicSignalsAndSlots(); - void simpleBindings(); - void autoComponentCreation(); - void propertyValueSource(); - void attachedProperties(); - void dynamicObjects(); - void customVariantTypes(); - void valueTypes(); - void cppnamespace(); - void aliasProperties(); - void componentCompositeType(); - void i18n(); - void i18n_data(); - void onCompleted(); - void scriptString(); - void defaultPropertyListOrder(); - void declaredPropertyValues(); - - void importsBuiltin_data(); - void importsBuiltin(); - void importsLocal_data(); - void importsLocal(); - void importsRemote_data(); - void importsRemote(); - void importsInstalled_data(); - void importsInstalled(); - void importsOrder_data(); - void importsOrder(); - - void qmlAttachedPropertiesObjectMethod(); - - // regression tests for crashes - void crash1(); - void crash2(); - -private: - QmlEngine engine; - void testType(const QString& qml, const QString& type); -}; - -#define VERIFY_ERRORS(errorfile) \ - if (!errorfile) { \ - if (qgetenv("DEBUG") != "" && !component.errors().isEmpty()) \ - qWarning() << "Unexpected Errors:" << component.errors(); \ - QVERIFY(!component.isError()); \ - QVERIFY(component.errors().isEmpty()); \ - } else { \ - QFile file(QLatin1String(SRCDIR) + QLatin1String("/data/") + QLatin1String(errorfile)); \ - QVERIFY(file.open(QIODevice::ReadOnly)); \ - QByteArray data = file.readAll(); \ - file.close(); \ - QList<QByteArray> expected = data.split('\n'); \ - expected.removeAll(QByteArray("")); \ - QList<QmlError> errors = component.errors(); \ - QList<QByteArray> actual; \ - for (int ii = 0; ii < errors.count(); ++ii) { \ - const QmlError &error = errors.at(ii); \ - QByteArray errorStr = QByteArray::number(error.line()) + ":" + \ - QByteArray::number(error.column()) + ":" + \ - error.description().toUtf8(); \ - actual << errorStr; \ - } \ - if (qgetenv("DEBUG") != "" && expected != actual) \ - qWarning() << "Expected:" << expected << "Actual:" << actual; \ - if (qgetenv("QMLLANGUAGE_UPDATEERRORS") != "" && expected != actual) {\ - QFile file(QLatin1String("data/") + QLatin1String(errorfile)); \ - QVERIFY(file.open(QIODevice::WriteOnly)); \ - for (int ii = 0; ii < actual.count(); ++ii) { \ - file.write(actual.at(ii)); file.write("\n"); \ - } \ - file.close(); \ - } else { \ - QCOMPARE(expected, actual); \ - } \ - } - -inline QUrl TEST_FILE(const QString &filename) -{ - QFileInfo fileInfo(__FILE__); - return QUrl::fromLocalFile(fileInfo.absoluteDir().filePath(QLatin1String("data/") + filename)); -} - -inline QUrl TEST_FILE(const char *filename) -{ - return TEST_FILE(QLatin1String(filename)); -} - -void tst_qmllanguage::initTestCase() -{ - registerTypes(); - - QML_REGISTER_TYPE(com.nokia.Test, 0, 0, TestTP, TestType) - QML_REGISTER_TYPE(com.nokia.Test, 1, 0, Test, TestType) - QML_REGISTER_TYPE(com.nokia.Test, 1, 5, Test, TestType) - QML_REGISTER_TYPE(com.nokia.Test, 1, 8, Test, TestType2) - QML_REGISTER_TYPE(com.nokia.Test, 1, 9, OldTest, TestType) - QML_REGISTER_TYPE(com.nokia.Test, 1, 12, Test, TestType2) - - // Create locale-specific file - // For POSIX, this will just be data/I18nType.qml, since POSIX is 7-bit - // For iso8859-1 locale, this will just be data/I18nType?????.qml where ????? is 5 8-bit characters - // For utf-8 locale, this will be data/I18nType??????????.qml where ?????????? is 5 8-bit characters, UTF-8 encoded - QFile in(TEST_FILE(QLatin1String("I18nType30.qml")).toLocalFile()); - QVERIFY(in.open(QIODevice::ReadOnly)); - QFile out(TEST_FILE(QString::fromUtf8("I18nType\303\201\303\242\303\243\303\244\303\245.qml")).toLocalFile()); - QVERIFY(out.open(QIODevice::WriteOnly)); - out.write(in.readAll()); -} - -void tst_qmllanguage::cleanupTestCase() -{ - QVERIFY(QFile::remove(TEST_FILE(QString::fromUtf8("I18nType\303\201\303\242\303\243\303\244\303\245.qml")).toLocalFile())); -} - -void tst_qmllanguage::errors_data() -{ - QTest::addColumn<QString>("file"); - QTest::addColumn<QString>("errorFile"); - QTest::addColumn<bool>("create"); - - QTest::newRow("nonexistantProperty.1") << "nonexistantProperty.1.qml" << "nonexistantProperty.1.errors.txt" << false; - QTest::newRow("nonexistantProperty.2") << "nonexistantProperty.2.qml" << "nonexistantProperty.2.errors.txt" << false; - QTest::newRow("nonexistantProperty.3") << "nonexistantProperty.3.qml" << "nonexistantProperty.3.errors.txt" << false; - QTest::newRow("nonexistantProperty.4") << "nonexistantProperty.4.qml" << "nonexistantProperty.4.errors.txt" << false; - QTest::newRow("nonexistantProperty.5") << "nonexistantProperty.5.qml" << "nonexistantProperty.5.errors.txt" << false; - QTest::newRow("nonexistantProperty.6") << "nonexistantProperty.6.qml" << "nonexistantProperty.6.errors.txt" << false; - - QTest::newRow("wrongType (string for int)") << "wrongType.1.qml" << "wrongType.1.errors.txt" << false; - QTest::newRow("wrongType (int for bool)") << "wrongType.2.qml" << "wrongType.2.errors.txt" << false; - QTest::newRow("wrongType (bad rect)") << "wrongType.3.qml" << "wrongType.3.errors.txt" << false; - - QTest::newRow("wrongType (invalid enum)") << "wrongType.4.qml" << "wrongType.4.errors.txt" << false; - QTest::newRow("wrongType (int for uint)") << "wrongType.5.qml" << "wrongType.5.errors.txt" << false; - QTest::newRow("wrongType (string for real)") << "wrongType.6.qml" << "wrongType.6.errors.txt" << false; - QTest::newRow("wrongType (int for color)") << "wrongType.7.qml" << "wrongType.7.errors.txt" << false; - QTest::newRow("wrongType (int for date)") << "wrongType.8.qml" << "wrongType.8.errors.txt" << false; - QTest::newRow("wrongType (int for time)") << "wrongType.9.qml" << "wrongType.9.errors.txt" << false; - QTest::newRow("wrongType (int for datetime)") << "wrongType.10.qml" << "wrongType.10.errors.txt" << false; - QTest::newRow("wrongType (string for point)") << "wrongType.11.qml" << "wrongType.11.errors.txt" << false; - QTest::newRow("wrongType (color for size)") << "wrongType.12.qml" << "wrongType.12.errors.txt" << false; - QTest::newRow("wrongType (number string for int)") << "wrongType.13.qml" << "wrongType.13.errors.txt" << false; - QTest::newRow("wrongType (int for string)") << "wrongType.14.qml" << "wrongType.14.errors.txt" << false; - QTest::newRow("wrongType (int for url)") << "wrongType.15.qml" << "wrongType.15.errors.txt" << false; - - QTest::newRow("readOnly.1") << "readOnly.1.qml" << "readOnly.1.errors.txt" << false; - QTest::newRow("readOnly.2") << "readOnly.2.qml" << "readOnly.2.errors.txt" << false; - QTest::newRow("readOnly.3") << "readOnly.3.qml" << "readOnly.3.errors.txt" << false; - - QTest::newRow("listAssignment.2") << "listAssignment.2.qml" << "listAssignment.2.errors.txt" << false; - QTest::newRow("listAssignment.3") << "listAssignment.3.qml" << "listAssignment.3.errors.txt" << false; - - QTest::newRow("invalidID.1") << "invalidID.qml" << "invalidID.errors.txt" << false; - QTest::newRow("invalidID.2") << "invalidID.2.qml" << "invalidID.2.errors.txt" << false; - QTest::newRow("invalidID.3") << "invalidID.3.qml" << "invalidID.3.errors.txt" << false; - QTest::newRow("invalidID.4") << "invalidID.4.qml" << "invalidID.4.errors.txt" << false; - QTest::newRow("invalidID.5") << "invalidID.5.qml" << "invalidID.5.errors.txt" << false; - QTest::newRow("invalidID.6") << "invalidID.6.qml" << "invalidID.6.errors.txt" << false; - - QTest::newRow("unsupportedProperty") << "unsupportedProperty.qml" << "unsupportedProperty.errors.txt" << false; - QTest::newRow("nullDotProperty") << "nullDotProperty.qml" << "nullDotProperty.errors.txt" << true; - QTest::newRow("fakeDotProperty") << "fakeDotProperty.qml" << "fakeDotProperty.errors.txt" << false; - QTest::newRow("duplicateIDs") << "duplicateIDs.qml" << "duplicateIDs.errors.txt" << false; - QTest::newRow("unregisteredObject") << "unregisteredObject.qml" << "unregisteredObject.errors.txt" << false; - QTest::newRow("empty") << "empty.qml" << "empty.errors.txt" << false; - QTest::newRow("missingObject") << "missingObject.qml" << "missingObject.errors.txt" << false; - QTest::newRow("failingComponent") << "failingComponentTest.qml" << "failingComponent.errors.txt" << false; - QTest::newRow("missingSignal") << "missingSignal.qml" << "missingSignal.errors.txt" << false; - QTest::newRow("finalOverride") << "finalOverride.qml" << "finalOverride.errors.txt" << false; - QTest::newRow("customParserIdNotAllowed") << "customParserIdNotAllowed.qml" << "customParserIdNotAllowed.errors.txt" << false; - - QTest::newRow("invalidGroupedProperty.1") << "invalidGroupedProperty.1.qml" << "invalidGroupedProperty.1.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.2") << "invalidGroupedProperty.2.qml" << "invalidGroupedProperty.2.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.3") << "invalidGroupedProperty.3.qml" << "invalidGroupedProperty.3.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.4") << "invalidGroupedProperty.4.qml" << "invalidGroupedProperty.4.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.5") << "invalidGroupedProperty.5.qml" << "invalidGroupedProperty.5.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.6") << "invalidGroupedProperty.6.qml" << "invalidGroupedProperty.6.errors.txt" << false; - QTest::newRow("invalidGroupedProperty.7") << "invalidGroupedProperty.7.qml" << "invalidGroupedProperty.7.errors.txt" << true; - - QTest::newRow("importNamespaceConflict") << "importNamespaceConflict.qml" << "importNamespaceConflict.errors.txt" << false; - QTest::newRow("importVersionMissing (builtin)") << "importVersionMissingBuiltIn.qml" << "importVersionMissingBuiltIn.errors.txt" << false; - QTest::newRow("importVersionMissing (installed)") << "importVersionMissingInstalled.qml" << "importVersionMissingInstalled.errors.txt" << false; - QTest::newRow("invalidImportID") << "invalidImportID.qml" << "invalidImportID.errors.txt" << false; - - QTest::newRow("signal.1") << "signal.1.qml" << "signal.1.errors.txt" << false; - QTest::newRow("signal.2") << "signal.2.qml" << "signal.2.errors.txt" << false; - QTest::newRow("signal.3") << "signal.3.qml" << "signal.3.errors.txt" << false; - - QTest::newRow("property.1") << "property.1.qml" << "property.1.errors.txt" << false; - QTest::newRow("property.2") << "property.2.qml" << "property.2.errors.txt" << false; - QTest::newRow("property.3") << "property.3.qml" << "property.3.errors.txt" << false; - QTest::newRow("property.4") << "property.4.qml" << "property.4.errors.txt" << false; - QTest::newRow("property.5") << "property.5.qml" << "property.5.errors.txt" << false; - - QTest::newRow("Script.1") << "script.1.qml" << "script.1.errors.txt" << false; - QTest::newRow("Script.2") << "script.2.qml" << "script.2.errors.txt" << false; - QTest::newRow("Script.3") << "script.3.qml" << "script.3.errors.txt" << false; - QTest::newRow("Script.4") << "script.4.qml" << "script.4.errors.txt" << false; - QTest::newRow("Script.5") << "script.5.qml" << "script.5.errors.txt" << false; - QTest::newRow("Script.6") << "script.6.qml" << "script.6.errors.txt" << false; - QTest::newRow("Script.7") << "script.7.qml" << "script.7.errors.txt" << false; - QTest::newRow("Script.8") << "script.8.qml" << "script.8.errors.txt" << false; - QTest::newRow("Script.9") << "script.9.qml" << "script.9.errors.txt" << false; - QTest::newRow("Script.10") << "script.10.qml" << "script.10.errors.txt" << false; - QTest::newRow("Script.11") << "script.11.qml" << "script.11.errors.txt" << false; - QTest::newRow("Script.12") << "script.12.qml" << "script.12.errors.txt" << false; - - QTest::newRow("Component.1") << "component.1.qml" << "component.1.errors.txt" << false; - QTest::newRow("Component.2") << "component.2.qml" << "component.2.errors.txt" << false; - QTest::newRow("Component.3") << "component.3.qml" << "component.3.errors.txt" << false; - QTest::newRow("Component.4") << "component.4.qml" << "component.4.errors.txt" << false; - QTest::newRow("Component.5") << "component.5.qml" << "component.5.errors.txt" << false; - QTest::newRow("Component.6") << "component.6.qml" << "component.6.errors.txt" << false; - - QTest::newRow("invalidAttachedProperty.1") << "invalidAttachedProperty.1.qml" << "invalidAttachedProperty.1.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.2") << "invalidAttachedProperty.2.qml" << "invalidAttachedProperty.2.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.3") << "invalidAttachedProperty.3.qml" << "invalidAttachedProperty.3.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.4") << "invalidAttachedProperty.4.qml" << "invalidAttachedProperty.4.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.5") << "invalidAttachedProperty.5.qml" << "invalidAttachedProperty.5.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.6") << "invalidAttachedProperty.6.qml" << "invalidAttachedProperty.6.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.7") << "invalidAttachedProperty.7.qml" << "invalidAttachedProperty.7.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.8") << "invalidAttachedProperty.8.qml" << "invalidAttachedProperty.8.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.9") << "invalidAttachedProperty.9.qml" << "invalidAttachedProperty.9.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.10") << "invalidAttachedProperty.10.qml" << "invalidAttachedProperty.10.errors.txt" << false; - QTest::newRow("invalidAttachedProperty.11") << "invalidAttachedProperty.11.qml" << "invalidAttachedProperty.11.errors.txt" << false; - - QTest::newRow("nestedErrors") << "nestedErrors.qml" << "nestedErrors.errors.txt" << false; - QTest::newRow("defaultGrouped") << "defaultGrouped.qml" << "defaultGrouped.errors.txt" << false; - QTest::newRow("emptySignal") << "emptySignal.qml" << "emptySignal.errors.txt" << false; - QTest::newRow("doubleSignal") << "doubleSignal.qml" << "doubleSignal.errors.txt" << false; - QTest::newRow("invalidRoot") << "invalidRoot.qml" << "invalidRoot.errors.txt" << false; - QTest::newRow("missingValueTypeProperty") << "missingValueTypeProperty.qml" << "missingValueTypeProperty.errors.txt" << false; - QTest::newRow("objectValueTypeProperty") << "objectValueTypeProperty.qml" << "objectValueTypeProperty.errors.txt" << false; -} - - -void tst_qmllanguage::errors() -{ - QFETCH(QString, file); - QFETCH(QString, errorFile); - QFETCH(bool, create); - - if (file == "invalidID.6.qml") - QTest::ignoreMessage(QtWarningMsg, "id \"StartsWithUpperCase\" is invalid: ids cannot start with uppercase letters"); - - QmlComponent component(&engine, TEST_FILE(file)); - - if(create) { - QObject *object = component.create(); - QVERIFY(object == 0); - } - - VERIFY_ERRORS(errorFile.toLatin1().constData()); -} - -void tst_qmllanguage::simpleObject() -{ - QmlComponent component(&engine, TEST_FILE("simpleObject.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); -} - -void tst_qmllanguage::simpleContainer() -{ - QmlComponent component(&engine, TEST_FILE("simpleContainer.qml")); - VERIFY_ERRORS(0); - MyContainer *container= qobject_cast<MyContainer*>(component.create()); - QVERIFY(container != 0); - QCOMPARE(container->getChildren()->count(),2); -} - -void tst_qmllanguage::interfaceProperty() -{ - QmlComponent component(&engine, TEST_FILE("interfaceProperty.qml")); - VERIFY_ERRORS(0); - MyQmlObject *object = qobject_cast<MyQmlObject*>(component.create()); - QVERIFY(object != 0); - QVERIFY(object->interface()); - QVERIFY(object->interface()->id == 913); -} - -void tst_qmllanguage::interfaceQList() -{ - QmlComponent component(&engine, TEST_FILE("interfaceQList.qml")); - VERIFY_ERRORS(0); - MyContainer *container= qobject_cast<MyContainer*>(component.create()); - QVERIFY(container != 0); - QVERIFY(container->getQListInterfaces()->count() == 2); - for(int ii = 0; ii < 2; ++ii) - QVERIFY(container->getQListInterfaces()->at(ii)->id == 913); -} - -void tst_qmllanguage::assignObjectToSignal() -{ - QmlComponent component(&engine, TEST_FILE("assignObjectToSignal.qml")); - VERIFY_ERRORS(0); - MyQmlObject *object = qobject_cast<MyQmlObject *>(component.create()); - QVERIFY(object != 0); - QTest::ignoreMessage(QtWarningMsg, "MyQmlObject::basicSlot"); - emit object->basicSignal(); -} - -void tst_qmllanguage::assignObjectToVariant() -{ - QmlComponent component(&engine, TEST_FILE("assignObjectToVariant.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QVariant v = object->property("a"); - QVERIFY(v.userType() == qMetaTypeId<QObject *>()); -} - -void tst_qmllanguage::assignLiteralSignalProperty() -{ - QmlComponent component(&engine, TEST_FILE("assignLiteralSignalProperty.qml")); - VERIFY_ERRORS(0); - MyQmlObject *object = qobject_cast<MyQmlObject *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->onLiteralSignal(), 10); -} - -// Test is an external component can be loaded and assigned (to a qlist) -void tst_qmllanguage::assignQmlComponent() -{ - QmlComponent component(&engine, TEST_FILE("assignQmlComponent.qml")); - VERIFY_ERRORS(0); - MyContainer *object = qobject_cast<MyContainer *>(component.create()); - QVERIFY(object != 0); - QVERIFY(object->getChildren()->count() == 1); - QObject *child = object->getChildren()->at(0); - QCOMPARE(child->property("x"), QVariant(10)); - QCOMPARE(child->property("y"), QVariant(11)); -} - -// Test literal assignment to all the basic types -void tst_qmllanguage::assignBasicTypes() -{ - QmlComponent component(&engine, TEST_FILE("assignBasicTypes.qml")); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->flagProperty(), MyTypeObject::FlagVal1 | MyTypeObject::FlagVal3); - QCOMPARE(object->enumProperty(), MyTypeObject::EnumVal2); - QCOMPARE(object->stringProperty(), QString("Hello World!")); - QCOMPARE(object->uintProperty(), uint(10)); - QCOMPARE(object->intProperty(), -19); - QCOMPARE((float)object->realProperty(), float(23.2)); - QCOMPARE((float)object->doubleProperty(), float(-19.7)); - QCOMPARE((float)object->floatProperty(), float(8.5)); - QCOMPARE(object->colorProperty(), QColor("red")); - QCOMPARE(object->dateProperty(), QDate(1982, 11, 25)); - QCOMPARE(object->timeProperty(), QTime(11, 11, 32)); - QCOMPARE(object->dateTimeProperty(), QDateTime(QDate(2009, 5, 12), QTime(13, 22, 1))); - QCOMPARE(object->pointProperty(), QPoint(99,13)); - QCOMPARE(object->pointFProperty(), QPointF((float)-10.1, (float)12.3)); - QCOMPARE(object->sizeProperty(), QSize(99, 13)); - QCOMPARE(object->sizeFProperty(), QSizeF((float)0.1, (float)0.2)); - QCOMPARE(object->rectProperty(), QRect(9, 7, 100, 200)); - QCOMPARE(object->rectFProperty(), QRectF((float)1000.1, (float)-10.9, (float)400, (float)90.99)); - QCOMPARE(object->boolProperty(), true); - QCOMPARE(object->variantProperty(), QVariant("Hello World!")); - QCOMPARE(object->vectorProperty(), QVector3D(10, 1, 2.2)); - QCOMPARE(object->urlProperty(), component.url().resolved(QUrl("main.qml"))); - QVERIFY(object->objectProperty() != 0); - MyTypeObject *child = qobject_cast<MyTypeObject *>(object->objectProperty()); - QVERIFY(child != 0); - QCOMPARE(child->intProperty(), 8); -} - -// Test edge case type assignments -void tst_qmllanguage::assignTypeExtremes() -{ - QmlComponent component(&engine, TEST_FILE("assignTypeExtremes.qml")); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->uintProperty(), 0xEE6B2800); - QCOMPARE(object->intProperty(), -0x77359400); -} - -// Test that a composite type can assign to a property of its base type -void tst_qmllanguage::assignCompositeToType() -{ - QmlComponent component(&engine, TEST_FILE("assignCompositeToType.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); -} - -// Tests that custom parser types can be instantiated -void tst_qmllanguage::customParserTypes() -{ - QmlComponent component(&engine, TEST_FILE("customParserTypes.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QVERIFY(object->property("count") == QVariant(2)); -} - -// Tests that the root item can be a custom component -void tst_qmllanguage::rootAsQmlComponent() -{ - QmlComponent component(&engine, TEST_FILE("rootAsQmlComponent.qml")); - VERIFY_ERRORS(0); - MyContainer *object = qobject_cast<MyContainer *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->property("x"), QVariant(11)); - QCOMPARE(object->getChildren()->count(), 2); -} - -// Tests that components can be specified inline -void tst_qmllanguage::inlineQmlComponents() -{ - QmlComponent component(&engine, TEST_FILE("inlineQmlComponents.qml")); - VERIFY_ERRORS(0); - MyContainer *object = qobject_cast<MyContainer *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->getChildren()->count(), 1); - QmlComponent *comp = qobject_cast<QmlComponent *>(object->getChildren()->at(0)); - QVERIFY(comp != 0); - MyQmlObject *compObject = qobject_cast<MyQmlObject *>(comp->create()); - QVERIFY(compObject != 0); - QCOMPARE(compObject->value(), 11); -} - -// Tests that types that have an id property have it set -void tst_qmllanguage::idProperty() -{ - QmlComponent component(&engine, TEST_FILE("idProperty.qml")); - VERIFY_ERRORS(0); - MyContainer *object = qobject_cast<MyContainer *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->getChildren()->count(), 1); - MyTypeObject *child = - qobject_cast<MyTypeObject *>(object->getChildren()->at(0)); - QVERIFY(child != 0); - QCOMPARE(child->id(), QString("myObjectId")); - QCOMPARE(object->property("object"), QVariant::fromValue((QObject *)child)); -} - -// Tests that signals can be assigned to -void tst_qmllanguage::assignSignal() -{ - QmlComponent component(&engine, TEST_FILE("assignSignal.qml")); - VERIFY_ERRORS(0); - MyQmlObject *object = qobject_cast<MyQmlObject *>(component.create()); - QVERIFY(object != 0); - QTest::ignoreMessage(QtWarningMsg, "MyQmlObject::basicSlot"); - emit object->basicSignal(); - QTest::ignoreMessage(QtWarningMsg, "MyQmlObject::basicSlotWithArgs(9)"); - emit object->basicParameterizedSignal(9); -} - -// Tests the creation and assignment of dynamic properties -void tst_qmllanguage::dynamicProperties() -{ - QmlComponent component(&engine, TEST_FILE("dynamicProperties.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QCOMPARE(object->property("intProperty"), QVariant(10)); - QCOMPARE(object->property("boolProperty"), QVariant(false)); - QCOMPARE(object->property("doubleProperty"), QVariant(-10.1)); - QCOMPARE(object->property("realProperty"), QVariant((qreal)-19.9)); - QCOMPARE(object->property("stringProperty"), QVariant("Hello World!")); - QCOMPARE(object->property("urlProperty"), QVariant(TEST_FILE("main.qml"))); - QCOMPARE(object->property("colorProperty"), QVariant(QColor("red"))); - QCOMPARE(object->property("dateProperty"), QVariant(QDate(1945, 9, 2))); - QCOMPARE(object->property("varProperty"), QVariant("Hello World!")); - QCOMPARE(object->property("variantProperty"), QVariant(12)); -} - -// Test that nested types can use dynamic properties -void tst_qmllanguage::dynamicPropertiesNested() -{ - QmlComponent component(&engine, TEST_FILE("dynamicPropertiesNested.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("super_a").toInt(), 11); // Overridden - QCOMPARE(object->property("super_c").toInt(), 14); // Inherited - QCOMPARE(object->property("a").toInt(), 13); // New - QCOMPARE(object->property("b").toInt(), 12); // New - - delete object; -} - -// Tests the creation and assignment to dynamic list properties -void tst_qmllanguage::listProperties() -{ - QmlComponent component(&engine, TEST_FILE("listProperties.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("test").toInt(), 2); -} - -// Tests the creation and assignment of dynamic object properties -// ### Not complete -void tst_qmllanguage::dynamicObjectProperties() -{ - QmlComponent component(&engine, TEST_FILE("dynamicObjectProperties.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QVERIFY(object->property("objectProperty") == qVariantFromValue((QObject*)0)); - QVERIFY(object->property("objectProperty2") != qVariantFromValue((QObject*)0)); -} - -// Tests the declaration of dynamic signals and slots -void tst_qmllanguage::dynamicSignalsAndSlots() -{ - QTest::ignoreMessage(QtDebugMsg, "1921"); - - QmlComponent component(&engine, TEST_FILE("dynamicSignalsAndSlots.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QVERIFY(object->metaObject()->indexOfMethod("signal1()") != -1); - QVERIFY(object->metaObject()->indexOfMethod("signal2()") != -1); - QVERIFY(object->metaObject()->indexOfMethod("slot1()") != -1); - QVERIFY(object->metaObject()->indexOfMethod("slot2()") != -1); - - QCOMPARE(object->property("test").toInt(), 0); - QMetaObject::invokeMethod(object, "slot3", Qt::DirectConnection, Q_ARG(QVariant, QVariant(10))); - QCOMPARE(object->property("test").toInt(), 10); -} - -void tst_qmllanguage::simpleBindings() -{ - QmlComponent component(&engine, TEST_FILE("simpleBindings.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QCOMPARE(object->property("value1"), QVariant(10)); - QCOMPARE(object->property("value2"), QVariant(10)); - QCOMPARE(object->property("value3"), QVariant(21)); - QCOMPARE(object->property("value4"), QVariant(10)); - QCOMPARE(object->property("objectProperty"), QVariant::fromValue(object)); -} - -void tst_qmllanguage::autoComponentCreation() -{ - QmlComponent component(&engine, TEST_FILE("autoComponentCreation.qml")); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - QVERIFY(object->componentProperty() != 0); - MyTypeObject *child = qobject_cast<MyTypeObject *>(object->componentProperty()->create()); - QVERIFY(child != 0); - QCOMPARE(child->realProperty(), qreal(9)); -} - -void tst_qmllanguage::propertyValueSource() -{ - { - QmlComponent component(&engine, TEST_FILE("propertyValueSource.qml")); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - - QList<QObject *> valueSources; - QObjectList allChildren = object->findChildren<QObject*>(); - foreach (QObject *child, allChildren) { - if (qobject_cast<QmlPropertyValueSource *>(child)) - valueSources.append(child); - } - - QCOMPARE(valueSources.count(), 1); - MyPropertyValueSource *valueSource = - qobject_cast<MyPropertyValueSource *>(valueSources.at(0)); - QVERIFY(valueSource != 0); - QCOMPARE(valueSource->prop.object(), object); - QCOMPARE(valueSource->prop.name(), QString(QLatin1String("intProperty"))); - } - - { - QmlComponent component(&engine, TEST_FILE("propertyValueSource.2.qml")); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - - QList<QObject *> valueSources; - QObjectList allChildren = object->findChildren<QObject*>(); - foreach (QObject *child, allChildren) { - if (qobject_cast<QmlPropertyValueSource *>(child)) - valueSources.append(child); - } - - QCOMPARE(valueSources.count(), 1); - MyPropertyValueSource *valueSource = - qobject_cast<MyPropertyValueSource *>(valueSources.at(0)); - QVERIFY(valueSource != 0); - QCOMPARE(valueSource->prop.object(), object); - QCOMPARE(valueSource->prop.name(), QString(QLatin1String("intProperty"))); - } -} - -void tst_qmllanguage::attachedProperties() -{ - QmlComponent component(&engine, TEST_FILE("attachedProperties.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QObject *attached = qmlAttachedPropertiesObject<MyQmlObject>(object); - QVERIFY(attached != 0); - QCOMPARE(attached->property("value"), QVariant(10)); - QCOMPARE(attached->property("value2"), QVariant(13)); -} - -// Tests non-static object properties -void tst_qmllanguage::dynamicObjects() -{ - QmlComponent component(&engine, TEST_FILE("dynamicObject.1.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); -} - -// Tests the registration of custom variant string converters -void tst_qmllanguage::customVariantTypes() -{ - QmlComponent component(&engine, TEST_FILE("customVariantTypes.qml")); - VERIFY_ERRORS(0); - MyQmlObject *object = qobject_cast<MyQmlObject*>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->customType().a, 10); -} - -void tst_qmllanguage::valueTypes() -{ - QmlComponent component(&engine, TEST_FILE("valueTypes.qml")); - VERIFY_ERRORS(0); - - QString message = QLatin1String("QML MyTypeObject (") + component.url().toString() + - QLatin1String(":2:1) Binding loop detected for property \"rectProperty.width\""); - QTest::ignoreMessage(QtWarningMsg, qPrintable(message)); - QTest::ignoreMessage(QtWarningMsg, qPrintable(message)); - - MyTypeObject *object = qobject_cast<MyTypeObject*>(component.create()); - QVERIFY(object != 0); - - - QCOMPARE(object->rectProperty(), QRect(10, 11, 12, 13)); - QCOMPARE(object->rectProperty2(), QRect(10, 11, 12, 13)); - QCOMPARE(object->intProperty(), 10); - object->doAction(); - QCOMPARE(object->rectProperty(), QRect(12, 11, 14, 13)); - QCOMPARE(object->rectProperty2(), QRect(12, 11, 14, 13)); - QCOMPARE(object->intProperty(), 12); - - // ### -#if 0 - QmlMetaProperty p = QmlMetaProperty::createProperty(object, "rectProperty.x"); - QCOMPARE(p.read(), QVariant(12)); - p.write(13); - QCOMPARE(p.read(), QVariant(13)); - - quint32 r = QmlMetaPropertyPrivate::saveValueType(p.coreIndex(), p.valueTypeCoreIndex()); - QmlMetaProperty p2; - QmlMetaPropertyPrivate::restore(p2, r, object); - QCOMPARE(p2.read(), QVariant(13)); -#endif -} - -void tst_qmllanguage::cppnamespace() -{ - { - QmlComponent component(&engine, TEST_FILE("cppnamespace.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - delete object; - } - - { - QmlComponent component(&engine, TEST_FILE("cppnamespace.2.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - delete object; - } -} - -void tst_qmllanguage::aliasProperties() -{ - // Simple "int" alias - { - QmlComponent component(&engine, TEST_FILE("alias.1.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - // Read through alias - QCOMPARE(object->property("valueAlias").toInt(), 10); - object->setProperty("value", QVariant(13)); - QCOMPARE(object->property("valueAlias").toInt(), 13); - - // Write throught alias - object->setProperty("valueAlias", QVariant(19)); - QCOMPARE(object->property("valueAlias").toInt(), 19); - QCOMPARE(object->property("value").toInt(), 19); - - delete object; - } - - // Complex object alias - { - QmlComponent component(&engine, TEST_FILE("alias.2.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - // Read through alias - MyQmlObject *v = - qvariant_cast<MyQmlObject *>(object->property("aliasObject")); - QVERIFY(v != 0); - QCOMPARE(v->value(), 10); - - // Write through alias - MyQmlObject *v2 = new MyQmlObject(); - v2->setParent(object); - object->setProperty("aliasObject", qVariantFromValue(v2)); - MyQmlObject *v3 = - qvariant_cast<MyQmlObject *>(object->property("aliasObject")); - QVERIFY(v3 != 0); - QCOMPARE(v3, v2); - - delete object; - } - - // Nested aliases - { - QmlComponent component(&engine, TEST_FILE("alias.3.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("value").toInt(), 1892); - QCOMPARE(object->property("value2").toInt(), 1892); - - object->setProperty("value", QVariant(1313)); - QCOMPARE(object->property("value").toInt(), 1313); - QCOMPARE(object->property("value2").toInt(), 1313); - - object->setProperty("value2", QVariant(8080)); - QCOMPARE(object->property("value").toInt(), 8080); - QCOMPARE(object->property("value2").toInt(), 8080); - - delete object; - } - - // Enum aliases - { - QmlComponent component(&engine, TEST_FILE("alias.4.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("enumAlias").toInt(), 1); - - delete object; - } - - // Id aliases - { - QmlComponent component(&engine, TEST_FILE("alias.5.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QVariant v = object->property("otherAlias"); - QCOMPARE(v.userType(), qMetaTypeId<MyQmlObject*>()); - MyQmlObject *o = qvariant_cast<MyQmlObject*>(v); - QCOMPARE(o->value(), 10); - - delete o; - - v = object->property("otherAlias"); - QCOMPARE(v.userType(), qMetaTypeId<MyQmlObject*>()); - o = qvariant_cast<MyQmlObject*>(v); - QVERIFY(o == 0); - - delete object; - } - - // Nested aliases - this used to cause a crash - { - QmlComponent component(&engine, TEST_FILE("alias.6.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("a").toInt(), 1923); - } - - // Ptr Alias Cleanup - check that aliases to ptr types return 0 - // if the object aliased to is removed - { - QmlComponent component(&engine, TEST_FILE("alias.7.qml")); - VERIFY_ERRORS(0); - - QObject *object = component.create(); - QVERIFY(object != 0); - - QObject *object1 = qvariant_cast<QObject *>(object->property("object")); - QVERIFY(object1 != 0); - QObject *object2 = qvariant_cast<QObject *>(object1->property("object")); - QVERIFY(object2 != 0); - - QObject *alias = qvariant_cast<QObject *>(object->property("aliasedObject")); - QVERIFY(alias == object2); - - delete object1; - - QObject *alias2 = object; // "Random" start value - int status = -1; - void *a[] = { &alias2, 0, &status }; - QMetaObject::metacall(object, QMetaObject::ReadProperty, - object->metaObject()->indexOfProperty("aliasedObject"), a); - QVERIFY(alias2 == 0); - } - - // Simple composite type - { - QmlComponent component(&engine, TEST_FILE("alias.8.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("value").toInt(), 10); - - delete object; - } - - // Complex composite type - { - QmlComponent component(&engine, TEST_FILE("alias.9.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(object->property("value").toInt(), 10); - - delete object; - } -} - -// Test that the root element in a composite type can be a Component -void tst_qmllanguage::componentCompositeType() -{ - QmlComponent component(&engine, TEST_FILE("componentCompositeType.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); -} - -class TestType : public QObject { - Q_OBJECT -public: - TestType(QObject *p=0) : QObject(p) {} -}; - -class TestType2 : public QObject { - Q_OBJECT -public: - TestType2(QObject *p=0) : QObject(p) {} -}; - -void tst_qmllanguage::i18n_data() -{ - QTest::addColumn<QString>("file"); - QTest::addColumn<QString>("stringProperty"); - QTest::newRow("i18nStrings") << "i18nStrings.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245 (5 accented 'a' letters)"); - QTest::newRow("i18nDeclaredPropertyNames") << "i18nDeclaredPropertyNames.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245: 10"); - QTest::newRow("i18nDeclaredPropertyUse") << "i18nDeclaredPropertyUse.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245: 15"); - QTest::newRow("i18nScript") << "i18nScript.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245: 20"); - QTest::newRow("i18nType") << "i18nType.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245: 30"); - QTest::newRow("i18nNameSpace") << "i18nNameSpace.qml" << QString::fromUtf8("Test \303\241\303\242\303\243\303\244\303\245: 40"); -} - -void tst_qmllanguage::i18n() -{ - QFETCH(QString, file); - QFETCH(QString, stringProperty); - QmlComponent component(&engine, TEST_FILE(file)); - VERIFY_ERRORS(0); - MyTypeObject *object = qobject_cast<MyTypeObject *>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->stringProperty(), stringProperty); - - delete object; -} - -// Check that the Component::onCompleted attached property works -void tst_qmllanguage::onCompleted() -{ - QmlComponent component(&engine, TEST_FILE("onCompleted.qml")); - VERIFY_ERRORS(0); - QTest::ignoreMessage(QtDebugMsg, "Completed 6 10"); - QTest::ignoreMessage(QtDebugMsg, "Completed 6 10"); - QTest::ignoreMessage(QtDebugMsg, "Completed 10 11"); - QObject *object = component.create(); - QVERIFY(object != 0); -} - -// Check that assignments to QmlScriptString properties work -void tst_qmllanguage::scriptString() -{ - QmlComponent component(&engine, TEST_FILE("scriptString.qml")); - VERIFY_ERRORS(0); - - MyTypeObject *object = qobject_cast<MyTypeObject*>(component.create()); - QVERIFY(object != 0); - QCOMPARE(object->scriptProperty().script(), QString("foo + bar")); - QCOMPARE(object->scriptProperty().scopeObject(), object); - QCOMPARE(object->scriptProperty().context(), qmlContext(object)); - - QVERIFY(object->grouped() != 0); - QCOMPARE(object->grouped()->script().script(), QString("console.log(1921)")); - QCOMPARE(object->grouped()->script().scopeObject(), object); - QCOMPARE(object->grouped()->script().context(), qmlContext(object)); -} - -// Check that default property assignments are correctly spliced into explicit -// property assignments -void tst_qmllanguage::defaultPropertyListOrder() -{ - QmlComponent component(&engine, TEST_FILE("defaultPropertyListOrder.qml")); - VERIFY_ERRORS(0); - - MyContainer *container = qobject_cast<MyContainer *>(component.create()); - QVERIFY(container != 0); - - QCOMPARE(container->getChildren()->count(), 6); - QCOMPARE(container->getChildren()->at(0)->property("index"), QVariant(0)); - QCOMPARE(container->getChildren()->at(1)->property("index"), QVariant(1)); - QCOMPARE(container->getChildren()->at(2)->property("index"), QVariant(2)); - QCOMPARE(container->getChildren()->at(3)->property("index"), QVariant(3)); - QCOMPARE(container->getChildren()->at(4)->property("index"), QVariant(4)); - QCOMPARE(container->getChildren()->at(5)->property("index"), QVariant(5)); -} - -void tst_qmllanguage::declaredPropertyValues() -{ - QmlComponent component(&engine, TEST_FILE("declaredPropertyValues.qml")); - QEXPECT_FAIL("", "QTBUG-7860", Abort); - VERIFY_ERRORS(0); -} - -// Check that first child of qml is of given type. Empty type insists on error. -void tst_qmllanguage::testType(const QString& qml, const QString& type) -{ - QmlComponent component(&engine); - component.setData(qml.toUtf8(), TEST_FILE("empty.qml")); // just a file for relative local imports - - QTRY_VERIFY(!component.isLoading()); - - if (type.isEmpty()) { - QVERIFY(component.isError()); - } else { - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - QCOMPARE(QString(object->metaObject()->className()), type); - } -} - -QML_DECLARE_TYPE(TestType) -QML_DECLARE_TYPE(TestType2) - -// Import tests (QT-558) - -void tst_qmllanguage::importsBuiltin_data() -{ - // QT-610 - - QTest::addColumn<QString>("qml"); - QTest::addColumn<QString>("type"); - - // import built-ins - QTest::newRow("missing import") - << "Test {}" - << ""; - QTest::newRow("not in version 0.0") - << "import com.nokia.Test 0.0\n" - "Test {}" - << ""; - QTest::newRow("in version 0.0") - << "import com.nokia.Test 0.0\n" - "TestTP {}" - << "TestType"; - QTest::newRow("qualified in version 0.0") - << "import com.nokia.Test 0.0 as T\n" - "T.TestTP {}" - << "TestType"; - QTest::newRow("in version 1.0") - << "import com.nokia.Test 1.0\n" - "Test {}" - << "TestType"; - QTest::newRow("qualified wrong") - << "import com.nokia.Test 1.0 as T\n" // QT-610 - "Test {}" - << ""; - QTest::newRow("qualified right") - << "import com.nokia.Test 1.0 as T\n" - "T.Test {}" - << "TestType"; - QTest::newRow("qualified right but not in version 0.0") - << "import com.nokia.Test 0.0 as T\n" - "T.Test {}" - << ""; - QTest::newRow("in version 1.1") - << "import com.nokia.Test 1.1\n" - "Test {}" - << "TestType"; - QTest::newRow("in version 1.3") - << "import com.nokia.Test 1.3\n" - "Test {}" - << "TestType"; - QTest::newRow("in version 1.5") - << "import com.nokia.Test 1.5\n" - "Test {}" - << "TestType"; - QTest::newRow("changed in version 1.8") - << "import com.nokia.Test 1.8\n" - "Test {}" - << "TestType2"; - QTest::newRow("in version 1.12") - << "import com.nokia.Test 1.12\n" - "Test {}" - << "TestType2"; - QTest::newRow("old in version 1.9") - << "import com.nokia.Test 1.9\n" - "OldTest {}" - << "TestType"; - QTest::newRow("old in version 1.11") - << "import com.nokia.Test 1.11\n" - "OldTest {}" - << "TestType"; - QTest::newRow("multiversion 1") - << "import com.nokia.Test 1.11\n" - "import com.nokia.Test 1.12\n" - "Test {}" - << "TestType2"; - QTest::newRow("multiversion 2") - << "import com.nokia.Test 1.11\n" - "import com.nokia.Test 1.12\n" - "OldTest {}" - << "TestType"; - QTest::newRow("qualified multiversion 3") - << "import com.nokia.Test 1.0 as T0\n" - "import com.nokia.Test 1.8 as T8\n" - "T0.Test {}" - << "TestType"; - QTest::newRow("qualified multiversion 4") - << "import com.nokia.Test 1.0 as T0\n" - "import com.nokia.Test 1.8 as T8\n" - "T8.Test {}" - << "TestType2"; -} - -void tst_qmllanguage::importsBuiltin() -{ - QFETCH(QString, qml); - QFETCH(QString, type); - testType(qml,type); -} - -void tst_qmllanguage::importsLocal_data() -{ - QTest::addColumn<QString>("qml"); - QTest::addColumn<QString>("type"); - - // import locals - QTest::newRow("local import") - << "import \"subdir\"\n" // QT-613 - "Test {}" - << "QmlGraphicsRectangle"; - QTest::newRow("local import second") - << "import Qt 4.6\nimport \"subdir\"\n" - "Test {}" - << "QmlGraphicsRectangle"; - QTest::newRow("local import subsubdir") - << "import Qt 4.6\nimport \"subdir/subsubdir\"\n" - "SubTest {}" - << "QmlGraphicsRectangle"; - QTest::newRow("local import QTBUG-7721 A") - << "subdir.Test {}" // no longer allowed (QTBUG-7721) - << ""; - QTest::newRow("local import QTBUG-7721 B") - << "import \"subdir\" as X\n" - "X.subsubdir.SubTest {}" // no longer allowed (QTBUG-7721) - << ""; - QTest::newRow("local import as") - << "import \"subdir\" as T\n" - "T.Test {}" - << "QmlGraphicsRectangle"; - QTest::newRow("wrong local import as") - << "import \"subdir\" as T\n" - "Test {}" - << ""; - QTest::newRow("library precedence over local import") - << "import \"subdir\"\n" - "import com.nokia.Test 1.0\n" - "Test {}" - << "TestType"; -} - -void tst_qmllanguage::importsLocal() -{ - QFETCH(QString, qml); - QFETCH(QString, type); - testType(qml,type); -} - -void tst_qmllanguage::importsRemote_data() -{ - QTest::addColumn<QString>("qml"); - QTest::addColumn<QString>("type"); - - QString serverdir = "http://127.0.0.1:14445/qtest/declarative/qmllanguage"; - - QTest::newRow("remote import") << "import \""+serverdir+"\"\nTest {}" << "QmlGraphicsRectangle"; - QTest::newRow("remote import with subdir") << "import \""+serverdir+"\"\nTestSubDir {}" << "QmlGraphicsText"; - QTest::newRow("remote import with local") << "import \""+serverdir+"\"\nTestLocal {}" << "QmlGraphicsImage"; -} - -#include "testhttpserver.h" - -void tst_qmllanguage::importsRemote() -{ - QFETCH(QString, qml); - QFETCH(QString, type); - - TestHTTPServer server(14445); - server.serveDirectory(SRCDIR); - - testType(qml,type); -} - -void tst_qmllanguage::importsInstalled_data() -{ - // QT-610 - - QTest::addColumn<QString>("qml"); - QTest::addColumn<QString>("type"); - - // import installed - QTest::newRow("installed import 0") - << "import com.nokia.installedtest 0.0\n" - "InstalledTestTP {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import 0 as TP") - << "import com.nokia.installedtest 0.0 as TP\n" - "TP.InstalledTestTP {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import 1") - << "import com.nokia.installedtest 1.0\n" - "InstalledTest {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import 2") - << "import com.nokia.installedtest 1.3\n" - "InstalledTest {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import 3") - << "import com.nokia.installedtest 1.4\n" - "InstalledTest {}" - << "QmlGraphicsText"; - QTest::newRow("installed import 4") - << "import com.nokia.installedtest 1.10\n" - "InstalledTest {}" - << "QmlGraphicsText"; - QTest::newRow("installed import visibility") // QT-614 - << "import com.nokia.installedtest 1.4\n" - "PrivateType {}" - << ""; -} - -void tst_qmllanguage::importsInstalled() -{ - QFETCH(QString, qml); - QFETCH(QString, type); - testType(qml,type); -} - - -void tst_qmllanguage::importsOrder_data() -{ - QTest::addColumn<QString>("qml"); - QTest::addColumn<QString>("type"); - - QTest::newRow("installed import overrides 1") << - "import com.nokia.installedtest 1.0\n" - "import com.nokia.installedtest 1.4\n" - "InstalledTest {}" - << "QmlGraphicsText"; - QTest::newRow("installed import overrides 2") << - "import com.nokia.installedtest 1.4\n" - "import com.nokia.installedtest 1.0\n" - "InstalledTest {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import re-overrides 1") << - "import com.nokia.installedtest 1.4\n" - "import com.nokia.installedtest 1.0\n" - "import com.nokia.installedtest 1.4\n" - "InstalledTest {}" - << "QmlGraphicsText"; - QTest::newRow("installed import re-overrides 2") << - "import com.nokia.installedtest 1.4\n" - "import com.nokia.installedtest 1.0\n" - "import com.nokia.installedtest 1.4\n" - "import com.nokia.installedtest 1.0\n" - "InstalledTest {}" - << "QmlGraphicsRectangle"; - - QTest::newRow("installed import versus builtin 1") << - "import com.nokia.installedtest 1.5\n" - "import Qt 4.6\n" - "Rectangle {}" - << "QmlGraphicsRectangle"; - QTest::newRow("installed import versus builtin 2") << - "import Qt 4.6\n" - "import com.nokia.installedtest 1.5\n" - "Rectangle {}" - << "QmlGraphicsText"; - QTest::newRow("namespaces cannot be overridden by types 1") << - "import Qt 4.6 as Rectangle\n" - "import com.nokia.installedtest 1.5\n" - "Rectangle {}" - << ""; - QTest::newRow("namespaces cannot be overridden by types 2") << - "import Qt 4.6 as Rectangle\n" - "import com.nokia.installedtest 1.5\n" - "Rectangle.Image {}" - << "QmlGraphicsImage"; -} - -void tst_qmllanguage::importsOrder() -{ - QFETCH(QString, qml); - QFETCH(QString, type); - testType(qml,type); -} - -void tst_qmllanguage::qmlAttachedPropertiesObjectMethod() -{ - QObject object; - - QCOMPARE(qmlAttachedPropertiesObject<MyQmlObject>(&object, false), (QObject *)0); - QCOMPARE(qmlAttachedPropertiesObject<MyQmlObject>(&object, true), (QObject *)0); - - { - QmlComponent component(&engine, TEST_FILE("qmlAttachedPropertiesObjectMethod.1.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QCOMPARE(qmlAttachedPropertiesObject<MyQmlObject>(object, false), (QObject *)0); - QVERIFY(qmlAttachedPropertiesObject<MyQmlObject>(object, true) != 0); - } - - { - QmlComponent component(&engine, TEST_FILE("qmlAttachedPropertiesObjectMethod.2.qml")); - VERIFY_ERRORS(0); - QObject *object = component.create(); - QVERIFY(object != 0); - - QVERIFY(qmlAttachedPropertiesObject<MyQmlObject>(object, false) != 0); - QVERIFY(qmlAttachedPropertiesObject<MyQmlObject>(object, true) != 0); - } -} - -void tst_qmllanguage::crash1() -{ - QmlComponent component(&engine); - component.setData("import Qt 4.6\nComponent {}", QUrl()); -} - -void tst_qmllanguage::crash2() -{ - QmlComponent component(&engine, TEST_FILE("crash2.qml")); -} - -QTEST_MAIN(tst_qmllanguage) - -#include "tst_qmllanguage.moc" |