|
1 /* |
|
2 * Copyright (c) 2006 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: XIMP Framework Test Code |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef T_PRESENCEWATCHING_H |
|
19 #define T_PRESENCEWATCHING_H |
|
20 |
|
21 #include <ceunittestsuiteclass.h> |
|
22 #include <ximpbase.h> |
|
23 #include "prfwteststatuseventlistener.h" |
|
24 #include "prfwtestmessaging.h" |
|
25 |
|
26 class CXIMPTestContextWrapper; |
|
27 class CXIMPTestContextWrapperMgr; |
|
28 class CXIMPTestMessenger; |
|
29 class MPresenceCacheReader; |
|
30 |
|
31 /** |
|
32 * XIMP Framework Eunit tests. |
|
33 * |
|
34 * Tests for XIMP session management services. |
|
35 * |
|
36 * @since S60 v4.0 |
|
37 */ |
|
38 class T_PresenceWatching : public CEUnitTestSuiteClass |
|
39 { |
|
40 |
|
41 public: |
|
42 static T_PresenceWatching* NewL(); |
|
43 virtual ~T_PresenceWatching(); |
|
44 |
|
45 |
|
46 private: |
|
47 T_PresenceWatching(); |
|
48 void ConstructL(); |
|
49 |
|
50 |
|
51 |
|
52 private: // Test case functions |
|
53 |
|
54 void Setup_L(); |
|
55 void SetupMultiple_L(); |
|
56 void BindL(); |
|
57 void BindAllL(); |
|
58 void Teardown(); |
|
59 void UnbindL(); |
|
60 void UnbindAllL(); |
|
61 |
|
62 void T_SubscribePresentityPresence_Single_L(); |
|
63 void T_SubscribeHandlePresentityPresence_Single_L(); |
|
64 void T_SubscribePresentityPresenceChangeId_Single_L(); |
|
65 void T_UnsubscribeNotSubscribedPresentityPresence_Single_L(); |
|
66 void T_UnsubscribeNotSubscribedPresentityPresence_Multiple_L(); |
|
67 |
|
68 void T_SubscribePresentityPresence_Multiple_L(); |
|
69 void T_SubscribePresentityGroupMembersPresence_Single_L(); |
|
70 void T_UnsubscribeNotSubscribedPresentityGroupMembersPresence_Single_L(); |
|
71 void T_UnsubscribeNotSubscribedPresentityGroupMembersPresence_Multiple_L(); |
|
72 void T_ContentChangePresentityGroupMembersPresence_Single_L(); |
|
73 |
|
74 void T_ErrFromPlg_LeaveOnSubscribePresentityPresence_L(); |
|
75 void T_ErrFromPlg_LeaveOnSubscribePresentityGroupMembersPresence_L(); |
|
76 void T_ErrFromPlg_LeaveOnUnsubscribePresentityPresence_L(); |
|
77 void T_ErrFromPlg_LeaveOnUnsubscribePresentityGroupMembersPresence_L(); |
|
78 |
|
79 void T_SubscribeGroupMembersPresence_Multiple_L(); |
|
80 |
|
81 private: // Test helpers |
|
82 |
|
83 void SetupListenerReqCompleteL( CXIMPTestContextWrapper* aWrapper, TXIMPTestStatusEventTemplate aEventType ); |
|
84 void SetupListenerReqCompleteAllowEventsL( CXIMPTestContextWrapper* aWrapper, TXIMPTestStatusEventTemplate aEventTypes ); |
|
85 |
|
86 private: // Test data |
|
87 |
|
88 /** |
|
89 * Eunit test case table declaration. |
|
90 */ |
|
91 EUNIT_DECLARE_TEST_TABLE; |
|
92 |
|
93 // owned |
|
94 CXIMPTestContextWrapperMgr* iWrapperMgr; |
|
95 |
|
96 MPresenceCacheReader* iMPresenceCacheReader; |
|
97 }; |
|
98 |
|
99 |
|
100 #endif // T_PRESENCEWATCHING_H |
|
101 |
|
102 |
|
103 |
|
104 // end of file |
|
105 |
|
106 |
|
107 |
|
108 |