|
1 // Copyright (c) 2007-2009 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 #ifndef __CINC105767_H__ |
|
17 #define __CINC105767_H__ |
|
18 |
|
19 #include <e32base.h> |
|
20 #include <http.h> |
|
21 #include <http/mhttpfiltercreationcallback.h> |
|
22 #include <http/mhttpauthenticationcallback.h> |
|
23 #include "HttpTestCore.h" |
|
24 |
|
25 class RConnection; |
|
26 class CHTTPTestUtils; |
|
27 class CScriptFile; |
|
28 /* |
|
29 Test case for defect fix CINC105767. |
|
30 */ |
|
31 class CINC105767 : public CHttpTestTransBase, |
|
32 public MHTTPTransactionCallback |
|
33 { |
|
34 public: |
|
35 static CINC105767* NewL(TInt aTestNumber, CScriptFile* aIniSettingsFile); |
|
36 virtual ~CINC105767(); |
|
37 |
|
38 void MHFRunL(RHTTPTransaction aTransaction, |
|
39 const THTTPEvent& aEvent) ; |
|
40 TInt MHFRunError(TInt aError, RHTTPTransaction aTransaction, |
|
41 const THTTPEvent& aEvent) ; |
|
42 |
|
43 private: |
|
44 CINC105767(TInt aTestNumber, CScriptFile* aIniSettingsFile); |
|
45 const TDesC& TestName(); |
|
46 virtual void DoRunL(); |
|
47 virtual TInt RunError(TInt aErr); |
|
48 virtual void DoCancel(); |
|
49 void CloseConnection (); |
|
50 TBool IsConnectionActive ( RConnection& aConnection ); |
|
51 |
|
52 // methods inherited from MHTTPDataSupplier |
|
53 virtual TBool GetNextDataPart(TPtrC8& aDataChunk); |
|
54 void ReleaseData(); |
|
55 TInt OverallDataSize(); |
|
56 TInt Reset (); |
|
57 private: |
|
58 /** This has the instance of the settings.ini file. This instance is passed |
|
59 to ReplaceHostNameL() function which uses this instance to retrieve the |
|
60 data from settings.ini file. |
|
61 */ |
|
62 CScriptFile* iIniSettingsFile; |
|
63 |
|
64 protected: |
|
65 TInt iFailureError; |
|
66 TInt iTestNumber; |
|
67 TInt iExpectedError; |
|
68 }; |
|
69 |
|
70 #endif // __CINC105767_H__ |