//
// Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of the License "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description: 
//

LOAD_SUITE tcaf

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0001
//! @SYMTestCaseDesc 		Basic Bitset Test
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, sets some bits then check they are set properly
//! @SYMTestExpectedResults	Bitset construction is successful, set, unset works as expected
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0001
RUN_TEST_STEP 100 tcaf BasicBitsetStep
END_TESTCASE SEC-CAF-UTILS-0001

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0002
//! @SYMTestCaseDesc 		Bitset List Test
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, uses the setlist to set a list of bits
//! @SYMTestExpectedResults	Bitset construction is successful, setlist works as expected
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0002
RUN_TEST_STEP 100 tcaf BitsetListStep 
END_TESTCASE SEC-CAF-UTILS-0002

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0003
//! @SYMTestCaseDesc 		Bitset equality 1
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0003
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Equality1
END_TESTCASE SEC-CAF-UTILS-0003

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0004
//! @SYMTestCaseDesc 		Bitset equality 2
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0004
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Equality2
END_TESTCASE SEC-CAF-UTILS-0004

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0005
//! @SYMTestCaseDesc 		Bitset equality 3
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0005
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Equality3
END_TESTCASE SEC-CAF-UTILS-0005

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0006
//! @SYMTestCaseDesc 		Bitset Inequality 1
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are not equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are not equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0006
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Inequality1
END_TESTCASE SEC-CAF-UTILS-0006

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0007
//! @SYMTestCaseDesc 		Bitset Inequality 2
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are not equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are not equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0007
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Inequality2
END_TESTCASE SEC-CAF-UTILS-0007

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0008
//! @SYMTestCaseDesc 		Bitset Inequality 3
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs two bitset, sets some bits checks the bitsets are not equal
//! @SYMTestExpectedResults	Bitset construction is successful, bitsets are not equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0008
RUN_TEST_STEP 100 tcaf BitsetEqualityStep c:\tcaf\cafutils.ini Inequality3
END_TESTCASE SEC-CAF-UTILS-0008

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0009
//! @SYMTestCaseDesc 		Bitset Copy 1
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, copies it to another bitset, checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset copying is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0009
RUN_TEST_STEP 100 tcaf BitsetCopyStep c:\tcaf\cafutils.ini Copy1
END_TESTCASE SEC-CAF-UTILS-0009

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0010
//! @SYMTestCaseDesc 		Bitset Copy 2
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, copies it to another bitset, checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset copying is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0010
RUN_TEST_STEP 100 tcaf BitsetCopyStep c:\tcaf\cafutils.ini Copy2
END_TESTCASE SEC-CAF-UTILS-0010

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0011
//! @SYMTestCaseDesc 		Bitset Copy 3
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, copies it to another bitset, checks the bitsets are equal
//! @SYMTestExpectedResults	Bitset copying is successful, bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0011
RUN_TEST_STEP 100 tcaf BitsetCopyStep c:\tcaf\cafutils.ini Copy3
END_TESTCASE SEC-CAF-UTILS-0011

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0012
//! @SYMTestCaseDesc 		Bitset Serialise 1
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, writes it to a stream and read it back to another bitset, check the bitsets are equal
//! @SYMTestExpectedResults	Bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0012
RUN_TEST_STEP 100 tcaf BitsetSerialiseStep c:\tcaf\cafutils.ini Copy1
END_TESTCASE SEC-CAF-UTILS-0012

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0013
//! @SYMTestCaseDesc 		Bitset Serialise 2
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, writes it to a stream and read it back to another bitset, check the bitsets are equal
//! @SYMTestExpectedResults	Bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0013
RUN_TEST_STEP 100 tcaf BitsetSerialiseStep c:\tcaf\cafutils.ini Copy2
END_TESTCASE SEC-CAF-UTILS-0013

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0014
//! @SYMTestCaseDesc 		Bitset Serialise 3
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Constructs a bitset, writes it to a stream and read it back to another bitset, check the bitsets are equal
//! @SYMTestExpectedResults	Bitsets are equal
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0014
RUN_TEST_STEP 100 tcaf BitsetSerialiseStep c:\tcaf\cafutils.ini Copy3
END_TESTCASE SEC-CAF-UTILS-0014

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0015
//! @SYMTestCaseDesc 		Bitset Panic 1
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0015
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic1
END_TESTCASE SEC-CAF-UTILS-0015

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0016
//! @SYMTestCaseDesc 		Bitset Panic 2
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0016
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic2
END_TESTCASE SEC-CAF-UTILS-0016

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0017
//! @SYMTestCaseDesc 		Bitset Panic 3
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0017
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic3
END_TESTCASE SEC-CAF-UTILS-0017

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0018
//! @SYMTestCaseDesc 		Bitset Panic 4
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0018
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic4
END_TESTCASE SEC-CAF-UTILS-0018

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0019
//! @SYMTestCaseDesc 		Bitset Panic 5
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0019
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic5
END_TESTCASE SEC-CAF-UTILS-0019

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0020
//! @SYMTestCaseDesc 		Bitset Panic 6
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Attempts to access an out of range bit, should cause a panic
//! @SYMTestExpectedResults	Causes a CAFUTILS panic
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0020
RUN_PANIC_STEP_RESULT 0 CafUtils 100 tcaf BitsetPanicStep c:\tcaf\cafutils.ini Panic6
END_TESTCASE SEC-CAF-UTILS-0020

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0021
//! @SYMTestCaseDesc 		Check CCafMimeHeader can be serialized
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CCafMimeHeader, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CCafMimeHeader can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0021
RUN_TEST_STEP 100 tcaf CAFSupplierSerializeStep
END_TESTCASE SEC-CAF-UTILS-0021

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0022
//! @SYMTestCaseDesc 		Check that CDirStreamable can be serialised
//! @SYMREQ			REQ3691
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CDirStreamable, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CDirStreamable can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0022
RUN_TEST_STEP 100 tcaf CAFCDirStreamStep
END_TESTCASE SEC-CAF-UTILS-0022

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0023
//! @SYMTestCaseDesc 		Check that RAttributeSet can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a RAttributeSet, write it to a stream and then read it back again
//! @SYMTestExpectedResults	RAttributeSet can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0023
RUN_TEST_STEP 100 tcaf CAFRAttributeSetStreamStep 
END_TESTCASE SEC-CAF-UTILS-0023

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0024
//! @SYMTestCaseDesc 		Check that RStringAttributeSet can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a RStringAttributeSet, write it to a stream and then read it back again
//! @SYMTestExpectedResults	RStringAttributeSet can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0024
RUN_TEST_STEP 100 tcaf CAFRStringAttributeSetStreamStep
END_TESTCASE SEC-CAF-UTILS-0024

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0025
//! @SYMTestCaseDesc 		Check that CSupplierOutputFile can be serialised
//! @SYMPREQ			PREQ1951
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CSupplierOutputFile, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CSupplierOutputFile can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0025
RUN_TEST_STEP 100 tcaf CAFSupplierOutputFileStreamStep 
END_TESTCASE SEC-CAF-UTILS-0025

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0026
//! @SYMTestCaseDesc 		Check that CMetaDataArray can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CMetaDataArray, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CMetaDataArray can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0026
RUN_TEST_STEP 100 tcaf CAFMetaDataArrayStep 
END_TESTCASE SEC-CAF-UTILS-0026

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0027
//! @SYMTestCaseDesc 		Check that CEmbeddedObject can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CEmbeddedObject, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CEmbeddedObject can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0027
RUN_TEST_STEP 100 tcaf CAFEmbeddedObjectStep
END_TESTCASE SEC-CAF-UTILS-0027

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0028
//! @SYMTestCaseDesc 		Check that CVirtualPath can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CVirtualPath, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CVirtualPath can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0028
RUN_TEST_STEP 100 tcaf CAFVirtualPathStep c:\tcaf\cafutils.ini
END_TESTCASE SEC-CAF-UTILS-0028

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0029
//! @SYMTestCaseDesc 		Check that CRightsInfo object can be serialised
//! @SYMREQ			REQ3679
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CRightsInfo, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CRightsInfo can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0029
RUN_TEST_STEP 100 tcaf CAFRightsInfoStep
END_TESTCASE SEC-CAF-UTILS-0029

//! @file
//! @SYMTestCaseID 		SEC-CAF-UTILS-0030
//! @SYMTestCaseDesc 		Check that CStreamablePointerArray can be serialised
//! @SYMPREQ			PREQ780
//! @SYMTestStatus		Implemented
//! @SYMTestPriority		Critical
//! @SYMTestActions		Create a CStreamablePtrArray, write it to a stream and then read it back again
//! @SYMTestExpectedResults	CStreamablePtrArray can be serialised
//! @SYMTestType		UT
START_TESTCASE SEC-CAF-UTILS-0030
RUN_TEST_STEP 100 tcaf CAFStreamablePtrArrayStep
END_TESTCASE SEC-CAF-UTILS-0030

