|
1 // Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 /** |
|
17 @file |
|
18 @test |
|
19 @internalComponent |
|
20 */ |
|
21 |
|
22 #if (!defined __T_FMGRBURSIM__) |
|
23 #define __T_FMGRBURSIM__ |
|
24 |
|
25 #include "t_fmgrburdefs.h" |
|
26 #include <babackup.h> |
|
27 #include <e32property.h> |
|
28 |
|
29 /** |
|
30 * Simulation base class for simulating a backup and restore operation. |
|
31 * The functionality allows copying and restoring a feature.dat file, and |
|
32 * checking that the registration file exists. |
|
33 */ |
|
34 class CFeatMgrBURSim: public CBase |
|
35 { |
|
36 public: |
|
37 virtual ~CFeatMgrBURSim(); |
|
38 |
|
39 static CFeatMgrBURSim* NewLC(); |
|
40 public: |
|
41 |
|
42 /** Use external API to start a backup. */ |
|
43 void Simulate_StartBackupL(); |
|
44 /** Use external API to stop a backup. */ |
|
45 void Simulate_EndBackupL( TBool aNormal = ETrue ); |
|
46 /** Use external API to start a restore. */ |
|
47 void Simulate_StartRestoreL(); |
|
48 /** Use external API to stop a restore. */ |
|
49 void Simulate_EndRestoreL( TBool aNormal = ETrue ); |
|
50 |
|
51 |
|
52 void Simulate_StartUndefinedL(); |
|
53 void Simulate_EndUndefinedL( TBool aNormal = ETrue ); |
|
54 |
|
55 /** |
|
56 * Confirm that the registration.xml file is present. |
|
57 * @leave KErrNotFound if file not present. |
|
58 */ |
|
59 void Simulate_CheckRegFileL(); |
|
60 |
|
61 private: |
|
62 CFeatMgrBURSim(); |
|
63 void ConstructL(); |
|
64 private: |
|
65 CBaBackupSessionWrapper* iBackupClient; |
|
66 }; |
|
67 |
|
68 #endif |