camerauis/cameraxui/cxengine/tsrc/unit/unittest_cxestatemachine/unittest_cxestatemachine.h
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 #ifndef UNITTEST_CXESTATEMACHINE_H_ |
|
18 #define UNITTEST_CXESTATEMACHINE_H_ |
|
19 |
|
20 #include <QObject> |
|
21 |
|
22 class CxeStateMachineUnit; |
|
23 class CxeState; |
|
24 |
|
25 class UnitTestCxeStateMachine : public QObject |
|
26 { |
|
27 Q_OBJECT |
|
28 |
|
29 public: |
|
30 |
|
31 enum StateIds |
|
32 { |
|
33 StartId = 0x01, |
|
34 MiddleId = 0x02, |
|
35 EndId = 0x04, |
|
36 IsolatedId = 0x08, |
|
37 UnknownId = 16 |
|
38 }; |
|
39 |
|
40 UnitTestCxeStateMachine(); |
|
41 virtual ~UnitTestCxeStateMachine(); |
|
42 |
|
43 private slots: |
|
44 |
|
45 // before each test case |
|
46 void init(); |
|
47 // after each test case |
|
48 void cleanup(); |
|
49 |
|
50 void testAddState(); |
|
51 void testSetState(); |
|
52 void testSetInitialState(); |
|
53 void testStateId(); |
|
54 void testVerifyStateChange(); |
|
55 |
|
56 private: |
|
57 |
|
58 CxeStateMachineUnit *mStateMachine; |
|
59 |
|
60 CxeState *mStartState; |
|
61 CxeState *mMiddleState; |
|
62 CxeState *mEndState; |
|
63 CxeState *mIsolatedState; |
|
64 |
|
65 }; |
|
66 |
|
67 #endif /* UNITTEST_CXESTATEMACHINE_H_ */ |
|