|
1 // Copyright (c) 2002-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 #include "TestSuiteNetCon.h" |
|
17 #include "TestStepNetCon.h" |
|
18 |
|
19 |
|
20 EXPORT_C CTestSuiteNetCon* NewTestSuiteNetConL() |
|
21 // |
|
22 // NewTestSuiteNetConL is exported at ordinal 1 |
|
23 // this provides the interface to allow schedule test |
|
24 // to create instances of this test suite |
|
25 // |
|
26 { |
|
27 |
|
28 return new(ELeave) CTestSuiteNetCon(); |
|
29 } |
|
30 |
|
31 |
|
32 CTestSuiteNetCon::~CTestSuiteNetCon() |
|
33 // |
|
34 // D'tor |
|
35 // |
|
36 { |
|
37 } |
|
38 |
|
39 |
|
40 TPtrC CTestSuiteNetCon::GetVersion() |
|
41 // |
|
42 // Make a version string available for test system |
|
43 // |
|
44 { |
|
45 |
|
46 _LIT(KTxtVersion,"1.0"); |
|
47 return KTxtVersion(); |
|
48 } |
|
49 |
|
50 |
|
51 void CTestSuiteNetCon::AddTestStepL(CTestStepNetCon* aTestStep) |
|
52 // |
|
53 // Add a test step into the suite |
|
54 // |
|
55 { |
|
56 |
|
57 // test steps contain a pointer back to the suite which owns them |
|
58 aTestStep->iTestSuite = this; |
|
59 |
|
60 // add the step using tyhe base class method |
|
61 CTestSuite::AddTestStepL(aTestStep); |
|
62 } |
|
63 |
|
64 |
|
65 void CTestSuiteNetCon::InitialiseL() |
|
66 // |
|
67 // Constructor for NetCon test suite |
|
68 // this creates the NetCon test step and |
|
69 // stores it inside CTestSuiteNetCon |
|
70 // |
|
71 { |
|
72 |
|
73 // add test steps |
|
74 for(TInt i=1; i<14; ++i) |
|
75 { |
|
76 AddTestStepL(new(ELeave) CTestStepNetCon(i)); |
|
77 } |
|
78 } |
|
79 |