sl@0: // Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // sl@0: sl@0: #ifndef __TEXTUTILSTESTS_H__ sl@0: #define __TEXTUTILSTESTS_H__ sl@0: sl@0: // System includes sl@0: // sl@0: #include sl@0: sl@0: // sl@0: // sl@0: // TEXTUtils test data sl@0: // sl@0: // sl@0: sl@0: _LIT(KRemove0_base, " Hello there "); sl@0: _LIT(KRemove0_left, "Hello there "); sl@0: const TInt KRemove0_left_consumed = 4; sl@0: _LIT(KRemove0_right, " Hello there"); sl@0: const TInt KRemove0_right_consumed = 3; sl@0: _LIT(KRemove0_both, "Hello there"); sl@0: const TInt KRemove0_both_consumed = 7; sl@0: sl@0: const TInt KNumericValue0 = 1234567890; sl@0: _LIT(KDecRep0, "1234567890"); sl@0: _LIT(KHexRep0, "499602d2"); sl@0: const TBool KIsValid0 = ETrue; sl@0: sl@0: const TInt KNumericValue1 = -543210; sl@0: _LIT(KDecRep1, "-543210"); sl@0: _LIT(KHexRep1, "-849eA"); sl@0: const TBool KIsValid1 = ETrue; sl@0: sl@0: const TInt KNumericValue2 = 0; sl@0: _LIT(KDecRep2, ""); sl@0: _LIT(KHexRep2, ""); sl@0: const TBool KIsValid2 = EFalse; sl@0: sl@0: const TInt KNumericValue3 = 0; sl@0: _LIT(KDecRep3, "t500"); sl@0: _LIT(KHexRep3, "t1f4"); sl@0: const TBool KIsValid3 = EFalse; sl@0: sl@0: _LIT(KQuotedBuffer0, "this is the \"quoted string\" and this is not"); sl@0: _LIT(KQuotedString0, "quoted string"); sl@0: _LIT(KQuotedRemainder0, " and this is not"); sl@0: const TInt KExpectedError0 = KErrNone; sl@0: sl@0: _LIT(KQuotedBuffer1, "this is the \"quoted string\" and this is also \"string!\" but this is not"); sl@0: _LIT(KQuotedString1, "quoted string\" and this is also \"string!"); sl@0: _LIT(KQuotedRemainder1, " but this is not"); sl@0: const TInt KExpectedError1 = KErrNone; sl@0: sl@0: _LIT(KQuotedBuffer2, "this has no quoted string"); sl@0: _LIT(KQuotedString2, ""); sl@0: _LIT(KQuotedRemainder2, "this has no quoted string"); sl@0: const TInt KExpectedError2 = -5014; sl@0: sl@0: _LIT(KQuotedBuffer3, "this has no a malformed \"quoted string"); sl@0: _LIT(KQuotedString3, ""); sl@0: _LIT(KQuotedRemainder3, "this has no a malformed \"quoted string"); sl@0: const TInt KExpectedError3 = -5014; sl@0: sl@0: _LIT(KListBuffer0, "token0, token1 / token 2 is very long "); sl@0: _LIT(KListToken0_0, "token0"); sl@0: _LIT(KListToken0_1, "token1"); sl@0: _LIT(KListToken0_2, "token 2 is very long"); sl@0: _LIT(KListRemainder0, ""); sl@0: _LIT(KListSeparator0, ",/"); sl@0: sl@0: _LIT(KListBuffer1, "token0, token1 / token 2 # very long "); sl@0: _LIT(KListToken1_0, "token0"); sl@0: _LIT(KListToken1_1, "token1"); sl@0: _LIT(KListToken1_2, "token 2"); sl@0: _LIT(KListRemainder1, " very long "); sl@0: _LIT(KListSeparator1, ",/#"); sl@0: sl@0: _LIT(KListBuffer2, "token0, token1 , token 2 is very long "); sl@0: _LIT(KListToken2_0, "token0"); sl@0: _LIT(KListToken2_1, "token1"); sl@0: _LIT(KListToken2_2, "token 2 is very long"); sl@0: _LIT(KListRemainder2, ""); sl@0: const TUint KListSeparator2 = ','; sl@0: sl@0: _LIT(KListBuffer3, "token0/ token1 / token 2 / very long "); sl@0: _LIT(KListToken3_0, "token0"); sl@0: _LIT(KListToken3_1, "token1"); sl@0: _LIT(KListToken3_2, "token 2"); sl@0: _LIT(KListRemainder3, " very long "); sl@0: const TUint KListSeparator3 = '/'; sl@0: sl@0: #endif // __TEXTUTILSTESTS_H__