47
|
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 mpmediakeyhandler
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef TESTMPMEDIAKEYHANDLER_H
|
|
19 |
#define TESTMPMEDIAKEYHANDLER_H
|
|
20 |
|
|
21 |
#include <QtTest/QtTest>
|
|
22 |
|
|
23 |
class MpMediaKeyHandler;
|
|
24 |
class MpMediaKeyHandlerPrivate;
|
|
25 |
|
|
26 |
class TestMpMediaKeyHandler : public QObject
|
|
27 |
{
|
|
28 |
Q_OBJECT
|
|
29 |
|
|
30 |
public:
|
|
31 |
|
|
32 |
TestMpMediaKeyHandler();
|
|
33 |
virtual ~TestMpMediaKeyHandler();
|
|
34 |
|
|
35 |
// from QtTest
|
|
36 |
public slots:
|
|
37 |
|
|
38 |
void initTestCase();
|
|
39 |
void cleanupTestCase();
|
|
40 |
void init();
|
|
41 |
void cleanup();
|
|
42 |
|
|
43 |
// internal
|
|
44 |
private slots:
|
|
45 |
|
|
46 |
void testConstructor();
|
|
47 |
void testDestructor();
|
|
48 |
void testCommandPausePlayKey();
|
|
49 |
void testCommandPlayKey();
|
|
50 |
void testCommandStopKey();
|
|
51 |
void testCommandPauseKey();
|
|
52 |
void testCommandRewindKeyPress();
|
|
53 |
void testCommandRewindKeyRelease();
|
|
54 |
void testCommandFastForwardKeyPress();
|
|
55 |
void testCommandFastForwardKeyRelease();
|
|
56 |
void testCommandBackwardKey();
|
|
57 |
void testCommandForwardKey();
|
|
58 |
void testCommandVolumeUpKey();
|
|
59 |
void testCommandVolumeDownKey();
|
|
60 |
|
|
61 |
void testPlay();
|
|
62 |
void testTuneFunction();
|
|
63 |
void testSelectDiskFunction();
|
|
64 |
void testAudioInputFunction();
|
|
65 |
void testSelectAvInputFunction();
|
|
66 |
|
|
67 |
private:
|
|
68 |
|
|
69 |
MpMediaKeyHandler *mTest;
|
|
70 |
MpMediaKeyHandlerPrivate *mTestPrivate;
|
|
71 |
|
|
72 |
};
|
|
73 |
|
|
74 |
#endif // TESTMPMEDIAKEYHANDLER_H
|
|
75 |
|