First public contribution.
1 // Copyright (c) 1994-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 the License "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.
29 enum TTestType{ENotifierNone,ENotifierHang,ENotifierRepeat,ENotifierWithRepeat};
33 //forward declaration for all scsi protocol tests
34 GLDEF_C void t_scsi_prot();
37 GLDEF_C void TestIfEqual( TInt aValue, TInt aExpected, TInt aLine, char aFileName[]);
38 #define TEST_FOR_VALUE( r, expected ) TestIfEqual( r, expected, __LINE__, __FILE__)
40 #define TEST_SENSE_CODE( aSensePtr, aExpKey, aExtAddCode ) \
42 TRequestSenseData senseDataErr (aSensePtr); \
43 TEST_FOR_VALUE (senseDataErr.Key(), aExpKey); \
44 TEST_FOR_VALUE (senseDataErr.AdditionalCode(), aExtAddCode);\
48 #define TEST_SENSE_CODE_IF_SUPPORTED( aSensePtr, aExpKey, aExtAddCode ) \
49 TRequestSenseData senseDataErr (aSensePtr); \
51 if((senseDataErr.Key() == TSenseInfo::EIllegalRequest) && \
52 (senseDataErr.AdditionalCode() == TSenseInfo::EInvalidCmdCode)) \
54 RDebug::Print(_L("Prevent Media Removal command not supported by this build\n")); \
59 TEST_FOR_VALUE (senseDataErr.Key(), aExpKey); \
60 TEST_FOR_VALUE (senseDataErr.AdditionalCode(), aExtAddCode); \
65 #endif //__TMSMAIN_H__