equal
deleted
inserted
replaced
|
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: |
|
15 * |
|
16 */ |
|
17 |
|
18 #include <QtGui> |
|
19 #include <QtTest/QtTest> |
|
20 |
|
21 #include <hbapplication.h> |
|
22 |
|
23 #include "dialpadtest.h" |
|
24 #include "dialpadbutton.h" |
|
25 |
|
26 class ut_DialpadButton : public QObject |
|
27 { |
|
28 Q_OBJECT |
|
29 |
|
30 private slots: |
|
31 void initTestCase(); |
|
32 void cleanupTestCase(); |
|
33 |
|
34 void testButtonType(); |
|
35 |
|
36 private: |
|
37 DialpadButton *mButton; |
|
38 }; |
|
39 |
|
40 void ut_DialpadButton::initTestCase() |
|
41 { |
|
42 mButton = new DialpadButton(); |
|
43 } |
|
44 |
|
45 void ut_DialpadButton::cleanupTestCase() |
|
46 { |
|
47 delete mButton; |
|
48 } |
|
49 |
|
50 void ut_DialpadButton::testButtonType() |
|
51 { |
|
52 QVERIFY(mButton->buttonType()==DialpadButton::NumericButton); |
|
53 mButton->setButtonType(DialpadButton::FunctionButton); |
|
54 QVERIFY(mButton->buttonType()==DialpadButton::FunctionButton); |
|
55 } |
|
56 |
|
57 DIALPAD_TEST_MAIN(ut_DialpadButton) |
|
58 #include "ut_dialpadbutton.moc" |