|
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: Unit test for mpvolumeslider |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef TESTMPVOLUMESLIDER_H |
|
19 #define TESTMPVOLUMESLIDER_H |
|
20 |
|
21 #include <QtTest/QtTest> |
|
22 #include "mpcommondefs.h" |
|
23 |
|
24 class MpVolumeSlider; |
|
25 |
|
26 class TestMpVolumeSlider : public QObject |
|
27 { |
|
28 Q_OBJECT |
|
29 |
|
30 public: |
|
31 |
|
32 TestMpVolumeSlider(); |
|
33 virtual ~TestMpVolumeSlider(); |
|
34 |
|
35 signals: |
|
36 void triggerVolumePropertyChanged( MpCommon::MpVolumeProperty property, int value ); |
|
37 void triggerSliderPressed(); |
|
38 void triggerSliderReleased(); |
|
39 void triggerIconClicked(); |
|
40 void triggerValueChanged( int value ); |
|
41 |
|
42 // from QtTest |
|
43 public slots: |
|
44 |
|
45 void initTestCase(); |
|
46 void cleanupTestCase(); |
|
47 void init(); |
|
48 void cleanup(); |
|
49 |
|
50 // internal |
|
51 private slots: |
|
52 |
|
53 void testConstructor(); |
|
54 void testShowVolumeSlider(); |
|
55 void testHandleVolumeProperty(); |
|
56 void testSliderPressed(); |
|
57 void testSliderReleased(); |
|
58 void testMuteIconClicked(); |
|
59 void testVolumeSliderChanged(); |
|
60 void testInitializeVolumeSliderPopup(); |
|
61 |
|
62 private: |
|
63 |
|
64 MpVolumeSlider *mTest; |
|
65 |
|
66 |
|
67 }; |
|
68 |
|
69 #endif // TESTMPVOLUMESLIDER_H |
|
70 |