|
1 // Copyright (c) 2006-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 // Contains declaration of CTestStepProtocol class that is |
|
15 // base class for all test step classes in this test. |
|
16 // |
|
17 // |
|
18 |
|
19 /** |
|
20 @file TestStepProtocol.h |
|
21 */ |
|
22 #if (!defined __TESTSTEPPROTOCOL_H__) |
|
23 #define __TESTSTEPPROTOCOL_H__ |
|
24 |
|
25 #include <in_sock.h> |
|
26 #include <test/testexecutestepbase.h> |
|
27 #include <es_prot.h> |
|
28 #include <comms-infras/nifif.h> |
|
29 #include <es_mbuf.h> |
|
30 #include <dns_qry.h> |
|
31 #include <es_prot.h> |
|
32 #include "pdummy.h" |
|
33 |
|
34 class CTestStepProtocol : public CTestStep |
|
35 { |
|
36 public: |
|
37 |
|
38 CTestStepProtocol(); |
|
39 ~CTestStepProtocol(); |
|
40 |
|
41 struct TSocketThreadArg |
|
42 { |
|
43 CTestStepProtocol* iHandle; |
|
44 RSemaphore* iSem; |
|
45 TUint iNumSockets; |
|
46 }; |
|
47 |
|
48 protected: |
|
49 |
|
50 const TPtrC& EpocErrorToText(const TInt aErrCode); |
|
51 enum TVerdict doTestStepL(); |
|
52 virtual enum TVerdict InternalDoTestStepL() =0; |
|
53 |
|
54 // test threads |
|
55 static const TUint KNumTestSockets; |
|
56 static const TInt KNumExhaustiveSockets; |
|
57 static const TInt KNumStretchOpens; |
|
58 |
|
59 TServerProtocolDesc iDesc; |
|
60 CDummyProtocol* iDummy; |
|
61 |
|
62 private: |
|
63 TPtrC iErrText; |
|
64 TBuf<16> iErrBuf; // size must at least satisfy the number of digits used to represent a TInt |
|
65 }; |
|
66 |
|
67 |
|
68 #endif /* __TESTSTEPPROTOCOL_H__ */ |
|
69 |