os/ossrv/genericopenlibs/posixrealtimeextensions/test/testsharedmemory/src/tsharedmemory.cpp
Update contrib.
1 // Copyright (c) 2008-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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // Name : tsharedmemory.cpp
18 #include "tsharedmemory.h"
27 CTestsharedmemory::~CTestsharedmemory()
31 CTestsharedmemory::CTestsharedmemory(const TDesC& aStepName)
33 // MANDATORY Call to base class method to set up the human readable name for logging.
34 SetTestStepName(aStepName);
37 TVerdict CTestsharedmemory::doTestStepPreambleL()
40 SetTestStepResult(EPass);
41 return TestStepResult();
46 TVerdict CTestsharedmemory::doTestStepPostambleL()
50 return TestStepResult();
54 TVerdict CTestsharedmemory::doTestStepL()
57 if(TestStepName() == KTestsharedmemory1)
59 INFO_PRINTF1(_L("Testsharedmemory1():"));
60 err = Testsharedmemory1();
61 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
63 if(TestStepName() == KTestsharedmemory2)
65 INFO_PRINTF1(_L("Testsharedmemory2():"));
66 err = Testsharedmemory2();
67 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
69 if(TestStepName() == KTestsharedmemory3)
71 INFO_PRINTF1(_L("Testsharedmemory3():"));
72 err = Testsharedmemory3();
73 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
75 if(TestStepName() == KTestsharedmemory4)
77 INFO_PRINTF1(_L("Testsharedmemory4():"));
78 err = Testsharedmemory4();
79 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
81 if(TestStepName() == KTestsharedmemory5)
83 INFO_PRINTF1(_L("Testsharedmemory5():"));
84 err = Testsharedmemory5();
85 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
87 if(TestStepName() == KTestsharedmemory6)
89 INFO_PRINTF1(_L("Testsharedmemory6():"));
90 err = Testsharedmemory6();
91 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
93 if(TestStepName() == KTestsharedmemory7)
95 INFO_PRINTF1(_L("Testsharedmemory7():"));
96 err = Testsharedmemory7();
97 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
99 if(TestStepName() == KTestsharedmemory8)
101 INFO_PRINTF1(_L("Testsharedmemory8():"));
102 err = Testsharedmemory8();
103 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
105 if(TestStepName() == KTestsharedmemory9)
107 INFO_PRINTF1(_L("Testsharedmemory9():"));
108 err = Testsharedmemory9();
109 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
111 if(TestStepName() == KTestsharedmemory10)
113 INFO_PRINTF1(_L("Testsharedmemory10():"));
114 err = Testsharedmemory10();
115 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
117 if(TestStepName() == KTestsharedmemory11)
119 INFO_PRINTF1(_L("Testsharedmemory11():"));
120 err = Testsharedmemory11();
121 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
123 if(TestStepName() == KTestsharedmemory12)
125 INFO_PRINTF1(_L("Testsharedmemory12():"));
126 err = Testsharedmemory12();
127 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
129 if(TestStepName() == KTestsharedmemory13)
131 INFO_PRINTF1(_L("Testsharedmemory13():"));
132 err = Testsharedmemory13();
133 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
135 if(TestStepName() == KTestsharedmemory14)
137 INFO_PRINTF1(_L("Testsharedmemory14():"));
138 err = Testsharedmemory14();
139 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
141 if(TestStepName() == KTestsharedmemory15)
143 INFO_PRINTF1(_L("Testsharedmemory15():"));
144 err = Testsharedmemory15();
145 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
147 if(TestStepName() == KTestsharedmemory16)
149 INFO_PRINTF1(_L("Testsharedmemory16():"));
150 err = Testsharedmemory16();
151 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
153 if(TestStepName() == KTestsharedmemory17)
155 INFO_PRINTF1(_L("Testsharedmemory17():"));
156 err = Testsharedmemory17();
157 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
159 if(TestStepName() == KTestsharedmemory18)
161 INFO_PRINTF1(_L("Testsharedmemory18():"));
162 err = Testsharedmemory18();
163 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
165 if(TestStepName() == KTestsharedmemory19)
167 INFO_PRINTF1(_L("Testsharedmemory19():"));
168 err = Testsharedmemory19();
169 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
171 if(TestStepName() == KTestsharedmemory20)
173 INFO_PRINTF1(_L("Testsharedmemory20():"));
174 err = Testsharedmemory20();
175 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
177 if(TestStepName() == KTestsharedmemory21)
179 INFO_PRINTF1(_L("Testsharedmemory21():"));
180 err = Testsharedmemory21();
181 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
183 if(TestStepName() == KTestsharedmemory22)
185 INFO_PRINTF1(_L("Testsharedmemory22():"));
186 err = Testsharedmemory22();
187 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
189 if(TestStepName() == KTestsharedmemory23)
191 INFO_PRINTF1(_L("Testsharedmemory23():"));
192 err = Testsharedmemory23();
193 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
195 if(TestStepName() == KTestsharedmemory24)
197 INFO_PRINTF1(_L("Testsharedmemory24():"));
198 err = Testsharedmemory24();
199 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
201 if(TestStepName() == KTestsharedmemory25)
203 INFO_PRINTF1(_L("Testsharedmemory25():"));
204 err = Testsharedmemory25();
205 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
207 if(TestStepName() == KTestsharedmemory26)
209 INFO_PRINTF1(_L("Testsharedmemory26():"));
210 err = Testsharedmemory26();
211 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
213 if(TestStepName() == KTestsharedmemory27)
215 INFO_PRINTF1(_L("Testsharedmemory27():"));
216 err = Testsharedmemory27();
217 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
219 if(TestStepName() == KTestsharedmemory28)
221 INFO_PRINTF1(_L("Testsharedmemory28():"));
222 err = Testsharedmemory28();
223 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
225 if(TestStepName() == KTestsharedmemory29)
227 INFO_PRINTF1(_L("Testsharedmemory29():"));
228 err = Testsharedmemory29();
229 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
231 if(TestStepName() == KTestsharedmemory30)
233 INFO_PRINTF1(_L("Testsharedmemory30():"));
234 err = Testsharedmemory30();
235 SetTestStepResult(err ? static_cast<TVerdict>(err) : EPass);
237 return TestStepResult();