|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Wallpaper test. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "t_hsdomainmodel.h" |
|
20 #include "hswidgetcomponentdescriptor.h" |
|
21 |
|
22 void TestHsDomainModel::testWidgetComponentDescriptor() |
|
23 { |
|
24 HsWidgetComponentDescriptor widgetDescriptor; |
|
25 |
|
26 QVERIFY(!widgetDescriptor.isValid()); |
|
27 |
|
28 widgetDescriptor.setUri(QString("uri")); |
|
29 QVERIFY(!widgetDescriptor.isValid()); |
|
30 |
|
31 widgetDescriptor.setUri(QString("")); |
|
32 widgetDescriptor.setTitle(QString("title")); |
|
33 QVERIFY(!widgetDescriptor.isValid()); |
|
34 |
|
35 widgetDescriptor.setUri(QString("uri")); |
|
36 widgetDescriptor.setTitle(QString("title")); |
|
37 QVERIFY(widgetDescriptor.isValid()); |
|
38 |
|
39 widgetDescriptor.setVersion(QString("foobar")); |
|
40 QVERIFY(!widgetDescriptor.isValid()); |
|
41 widgetDescriptor.setVersion(QString("1.0")); |
|
42 widgetDescriptor.setServiceXml(QString("foobar")); |
|
43 QVERIFY(widgetDescriptor.isValid()); |
|
44 |
|
45 |
|
46 } |