# HG changeset patch # User Dremov Kirill (Nokia-D-MSW/Tampere) # Date 1263842003 -7200 # Node ID 468cfcb53fd169eb875fca808f051452982e038c # Parent 705ec7b86991bbfaf86920efc6e15ce63891d36f Revision: 201001 Kit: 201003 diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/pictbridgeengine/src/dpsptpnotifier.cpp --- a/usbclasses/pictbridgeengine/src/dpsptpnotifier.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/pictbridgeengine/src/dpsptpnotifier.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -72,8 +72,20 @@ IF_DEBUG(Print(_L(">>>CDpsPtpNotifier::ChangePtpPersonality"))); if (!IsActive()) { - iNotifier->iUsbW.SetPersonality(iStatus, KUsbPersonalityIdMTP, ETrue); - SetActive(); + TInt personalityId = KUsbPersonalityIdMTP; + iNotifier->iUsbM.GetCurrentPersonalityId(personalityId); + IF_DEBUG(Print(_L("CDpsPtpNotifier::ChangePtpPersonality, current personality= %d"), personalityId)); + if(KUsbPersonalityIdPCSuiteMTP == personalityId) + { + TRequestStatus* statusPtr = &iStatus; + User::RequestComplete(statusPtr, KErrNone); + SetActive(); + } + else + { + iNotifier->iUsbW.SetPersonality(iStatus, KUsbPersonalityIdMTP, ETrue); + SetActive(); + } } IF_DEBUG(Print(_L("<< diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/Bmarm/UsbObexClassControllerTestU.DEF --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/Bmarm/UsbObexClassControllerTestU.DEF Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - LibEntryL__FR13CTestModuleIf @ 1 NONAME R3UNUSED ; LibEntryL(CTestModuleIf &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/Bwins/UsbObexClassControllerTestU.DEF --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/Bwins/UsbObexClassControllerTestU.DEF Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - ?LibEntryL@@YAPAVCScriptBase@@AAVCTestModuleIf@@@Z @ 1 NONAME ; class CScriptBase * __cdecl LibEntryL(class CTestModuleIf &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/EABI/UsbObexClassControllerTestU.def --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/EABI/UsbObexClassControllerTestU.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,5 +0,0 @@ -EXPORTS - _Z9LibEntryLR13CTestModuleIf @ 1 NONAME - _ZTI27CUSBObexApiTestActiveObject @ 2 NONAME - _ZTV27CUSBObexApiTestActiveObject @ 3 NONAME - diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/conf/UsbObexClassControllerTest.cfg --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/conf/UsbObexClassControllerTest.cfg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,106 +0,0 @@ -[StifSettings] -CapsModifier= UsbObexClassControllerTest.exe -[EndStifSettings] - -// UsbObexClassControllerTest Module - total ... tc - -// UsbObexClassControllerTest Api Tests (... tc) - -//[Test] -//title Example Api Test -//create UsbObexClassControllerTest tester -//tester ExecuteApiTest ExampleApiTest -//delete tester -//[Endtest] - -[Test] -title Initialization Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest InitializationTest -delete tester -[Endtest] - -[Test] -title Start Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest StartTest -delete tester -[Endtest] - -[Test] -title Stop Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest StopTest -delete tester -[Endtest] - -[Test] -title InterfaceInfo Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest InterfaceInfoTest -delete tester -[Endtest] - -[Test] -title InterfaceLengthInfo Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest InterfaceLengthInfoTest -delete tester -[Endtest] - -[Test] -title NumberOfInterfacesInfo Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest NumberOfInterfacesInfoTest -delete tester -[Endtest] - -[Test] -title StartupPriorityInfo Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest StartupPriorityInfoTest -delete tester -[Endtest] - -[Test] -title StateInfo Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest StateInfoTest -delete tester -[Endtest] - -[Test] -title Owner Test -create UsbObexClassControllerTest tester -tester ExecuteApiTest OwnerTest -delete tester -[Endtest] - -// Add new api tests here -// ... - - -// UsbObexClassControllerTest Module Tests (... tc) - -//[Test] -//title Example Module Test -//create UsbObexClassControllerTest tester -//tester ExecuteModuleTest ExampleModuleTest -//delete tester -//[Endtest] - -// Add new module tests here -// ... - - -// UsbObexClassControllerTest Branch Tests (... tc) - -//[Test] -//title Example Branch Test -//create UsbObexClassControllerTest tester -//tester ExecuteBranchTest ExampleBranchTest -//delete tester -//[Endtest] - -// Add new branch tests here -// ... diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest.mmp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest.mmp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,50 +0,0 @@ -/*TYPE TESTCLASS*/ -/* -* 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 "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: -* -*/ - - -#if defined(__S60_) - // To get the OSEXT_LAYER_SYSTEMINCLUDE-definition - #include -#endif - -TARGET UsbObexClassControllerTest.dll -TARGETTYPE dll -UID 0x1000008D 0x101FB3E3 - -CAPABILITY NetworkControl LocalServices NetworkServices CommDD ProtServ - -DEFFILE UsbObexClassControllerTest.def - -MW_LAYER_SYSTEMINCLUDE - -USERINCLUDE ../inc - -SOURCEPATH ../src -SOURCE UsbObexClassControllerTest.cpp -SOURCE UsbObexClassControllerTestBlocks.cpp USBObexApiTestActiveObject.cpp UsbObexClassControllerTest_exe.cpp - -LIBRARY euser.lib -LIBRARY stiftestinterface.lib -LIBRARY stiftestengine.lib -LIBRARY usbclasscontroller.lib -LIBRARY ecom.lib - - -LANG SC - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_ats.pkg --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_ats.pkg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,62 +0,0 @@ -; -; 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 "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: -; - -; Languages -&EN - -; Provide value for uid -#{"STIF"},(0x00000000),1,1,0,TYPE=SA - -; Series60 product id for S60 3.0 -[0x101F7961], 0, 0, 0, {"Series60ProductID"} - -; Localised Vendor name -%{"Nokia"} - -; Unique Vendor name -:"Nokia" - -; Logo -; None - -; Package signature - Optional -; None - -; Start of Package body - -; Condition blocks -; None - -; Options list -; None - -; Install files -"\epoc32\release\armv5\udeb\UsbObexClassControllerTest.dll"-"c:\Sys\Bin\UsbObexClassControllerTest.dll" -"\epoc32\release\armv5\udeb\UsbObexClassControllerTest.exe"-"c:\Sys\Bin\UsbObexClassControllerTest.exe" - -"..\init\UsbObexClassControllerTest_ats.ini"-"e:\testing\init\UsbObexClassControllerTest.ini" -"..\conf\UsbObexClassControllerTest.cfg"-"e:\testing\conf\UsbObexClassControllerTest.cfg" - -; Embedded SIS -; None - -; End of Package body - -; PKG dependencies -; None - -; PKG capabilities -; None diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_exe.mmp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_exe.mmp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,42 +0,0 @@ -/*TYPE TESTCLASS*/ -/* -* 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 "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: -* -*/ - - -#if defined(__S60_) - #include -#endif - -TARGET UsbObexClassControllerTest.exe -TARGETTYPE exe - -CAPABILITY NetworkControl LocalServices NetworkServices CommDD ProtServ - -UID 0 0xEF4892C6 - -MW_LAYER_SYSTEMINCLUDE - -SOURCEPATH ../src - -SOURCE UsbObexClassControllerTest_exe.cpp - -LIBRARY euser.lib -LIBRARY stiftestinterface.lib - -EPOCSTACKSIZE 40960 - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_phone.pkg --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/UsbObexClassControllerTest_phone.pkg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,62 +0,0 @@ -; -; 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 "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: -; - -; Languages -&EN - -; Provide value for uid -#{"STIF"},(0x00000000),1,1,0,TYPE=SA - -; Series60 product id for S60 3.0 -[0x1028315F], 0, 0, 0, {"Series60ProductID"} - -; Localised Vendor name -%{"Nokia"} - -; Unique Vendor name -:"Nokia" - -; Logo -; None - -; Package signature - Optional -; None - -; Start of Package body - -; Condition blocks -; None - -; Options list -; None - -; Install files -"\epoc32\release\armv5\udeb\UsbObexClassControllerTest.dll"-"c:\Sys\Bin\UsbObexClassControllerTest.dll" -"\epoc32\release\armv5\udeb\UsbObexClassControllerTest.exe"-"c:\Sys\Bin\UsbObexClassControllerTest.exe" - -"..\init\UsbObexClassControllerTest_phone.ini"-"c:\testframework\testframework.ini" -"..\conf\UsbObexClassControllerTest.cfg"-"c:\testframework\UsbObexClassControllerTest.cfg" - -; Embedded SIS -; None - -; End of Package body - -; PKG dependencies -; None - -; PKG capabilities -; None diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/bld.inf --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/bld.inf Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,32 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - -PRJ_PLATFORMS -DEFAULT - -PRJ_TESTEXPORTS - -PRJ_EXPORTS - -PRJ_TESTMMPFILES -UsbObexClassControllerTest.mmp -UsbObexClassControllerTest_exe.mmp - -PRJ_MMPFILES - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/build_sis_ats.bat --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/build_sis_ats.bat Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,23 +0,0 @@ -@rem -@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -@rem All rights reserved. -@rem This component and the accompanying materials are made available -@rem under the terms of "Eclipse Public License v1.0" -@rem which accompanies this distribution, and is available -@rem at the URL "http://www.eclipse.org/legal/epl-v10.html". -@rem -@rem Initial Contributors: -@rem Nokia Corporation - initial contribution. -@rem -@rem Contributors: -@rem -@rem Description: -@rem - -call bldmake clean -call bldmake bldfiles - -call abld reallyclean armv5 -call abld test build armv5 -call makesis UsbObexClassControllerTest_ats.pkg -call signsis UsbObexClassControllerTest_ats.sis UsbObexClassControllerTest_ats.sisx rd.cer rd-key.pem diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/build_sis_phone.bat --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/group/build_sis_phone.bat Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,23 +0,0 @@ -@rem -@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -@rem All rights reserved. -@rem This component and the accompanying materials are made available -@rem under the terms of "Eclipse Public License v1.0" -@rem which accompanies this distribution, and is available -@rem at the URL "http://www.eclipse.org/legal/epl-v10.html". -@rem -@rem Initial Contributors: -@rem Nokia Corporation - initial contribution. -@rem -@rem Contributors: -@rem -@rem Description: -@rem - -call bldmake clean -call bldmake bldfiles - -call abld reallyclean armv5 -call abld test build armv5 -call makesis UsbObexClassControllerTest_phone.pkg -call signsis UsbObexClassControllerTest_phone.sis UsbObexClassControllerTest_phone.sisx rd.cer rd-key.pem \ No newline at end of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/inc/USBObexApiTestActiveObject.h --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/inc/USBObexApiTestActiveObject.h Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,54 +0,0 @@ -/* -* 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 "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: -* -*/ - -#ifndef USBOBEXAPITESTACTIVEOBJECT_H_ -#define USBOBEXAPITESTACTIVEOBJECT_H_ - -#include -#include -#include - -class CStifLogger; -class CUsbClassControllerPlugIn; - -class CUSBObexApiTestActiveObject : public CActive -{ -public: - static CUSBObexApiTestActiveObject* NewL - (CStifLogger* aLog, - CUsbClassControllerPlugIn* aUsbClassControllerPlugIn); - virtual ~CUSBObexApiTestActiveObject(); - - void Start(); - void Stop(); - -private: - CUSBObexApiTestActiveObject - (CStifLogger* aLog, - CUsbClassControllerPlugIn* aUsbClassControllerPlugIn); - void RunL(); - void DoCancel(); - void ConstructL(); - - -private: - CStifLogger* iLog; - CUsbClassControllerPlugIn* iUsbClassControllerPlugIn; - TUsbServiceState iUsbServiceState; -}; - -#endif /*USBOBEXAPITESTACTIVEOBJECT_H_*/ diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/inc/UsbObexClassControllerTest.h --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/inc/UsbObexClassControllerTest.h Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,240 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - - -#ifndef USBOBEXCLASSCONTROLLERTEST_H -#define USBOBEXCLASSCONTROLLERTEST_H - -// INCLUDES -#include -#include -#include -#include - -#include "USBObexApiTestActiveObject.h" -#include -#include -#include -#include -#include - -// CONSTANTS -//const ?type ?constant_var = ?constant; - -// MACROS -//#define ?macro ?macro_def -#define TEST_CLASS_VERSION_MAJOR 0 -#define TEST_CLASS_VERSION_MINOR 0 -#define TEST_CLASS_VERSION_BUILD 0 - -// Logging path -_LIT( KUsbObexClassControllerTestLogPath, "\\logs\\testframework\\UsbObexClassControllerTest\\" ); - -// Logging path for ATS - for phone builds comment this line -//_LIT( KUsbObexClassControllerTestLogPath, "e:\\testing\\stiflogs\\" ); - -// Log file -_LIT( KUsbObexClassControllerTestLogFile, "UsbObexClassControllerTest.txt" ); -_LIT( KUsbObexClassControllerTestLogFileWithTitle, "UsbObexClassControllerTest_[%S].txt" ); - -// FUNCTION PROTOTYPES -//?type ?function_name(?arg_list); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; -class CUsbObexClassControllerTest; -class CUsbClassControllerIterator; - -// DATA TYPES -//enum ?declaration - -enum TUsbObexClassControllerTestResult - { - ETestCasePassed, - ETestCaseFailed - }; - -//typedef ?declaration -//extern ?data_type; - -// CLASS DECLARATION - -/** -* CUsbObexClassControllerTest test class for STIF Test Framework TestScripter. -* ?other_description_lines -* -* @lib ?library -* @since ?Series60_version -*/ -NONSHARABLE_CLASS(CUsbObexClassControllerTest) : - public CScriptBase, - public MUsbClassControllerNotify - { - public: // Constructors and destructor - - /** - * Two-phased constructor. - */ - static CUsbObexClassControllerTest* NewL( CTestModuleIf& aTestModuleIf ); - - /** - * Destructor. - */ - virtual ~CUsbObexClassControllerTest(); - - public: // New functions - - /** - * ?member_description. - * @since ?Series60_version - * @param ?arg1 ?description - * @return ?description - */ - //?type ?member_function( ?type ?arg1 ); - - public: // Functions from base classes - - /** - * From CScriptBase Runs a script line. - * @since ?Series60_version - * @param aItem Script line containing method name and parameters - * @return Symbian OS error code - */ - virtual TInt RunMethodL( CStifItemParser& aItem ); - - /** - * overrider of pure virtual functions from MUsbClassControllerNotify class - */ - CUsbClassControllerIterator* UccnGetClassControllerIteratorL(); - void UccnError(TInt aError); - - protected: // New functions - - /** - * ?member_description. - * @since ?Series60_version - * @param ?arg1 ?description - * @return ?description - */ - //?type ?member_function( ?type ?arg1 ); - - protected: // Functions from base classes - - /** - * From ?base_class ?member_description - */ - //?type ?member_function(); - - private: - - /** - * C++ default constructor. - */ - CUsbObexClassControllerTest( CTestModuleIf& aTestModuleIf ); - - /** - * By default Symbian 2nd phase constructor is private. - */ - void ConstructL(); - - // Prohibit copy constructor if not deriving from CBase. - // ?classname( const ?classname& ); - // Prohibit assigment operator if not deriving from CBase. - // ?classname& operator=( const ?classname& ); - - /** - * Frees all resources allocated from test methods. - * @since ?Series60_version - */ - void Delete(); - - /** - * Test methods are listed below. - */ - - virtual TInt ExecuteApiTest( CStifItemParser& aItem ); - virtual TInt ExecuteModuleTest( CStifItemParser& aItem ); - virtual TInt ExecuteBranchTest( CStifItemParser& aItem ); - - /** - * Method used to log version of test class - */ - void SendTestClassVersion(); - - //ADD NEW METHOD DEC HERE - //[TestMethods] - Do not remove - - void DoExecuteApiTestL( TPtrC aApiTestName, TUsbObexClassControllerTestResult& aTestResult ); - - void ExampleApiTestL( TUsbObexClassControllerTestResult& aTestResult ); - - void DoExecuteModuleTestL( TPtrC aModuleTestName, TUsbObexClassControllerTestResult& aTestResult ); - - void ExampleModuleTestL( TUsbObexClassControllerTestResult& aTestResult ); - - void DoExecuteBranchTestL( TPtrC aBranchTestName, TUsbObexClassControllerTestResult& aTestResult ); - - void ExampleBranchTestL( TUsbObexClassControllerTestResult& aTestResult ); - - void InitializeTestObjectL(); - void DeleteTestObject(); - TInt InitializationTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt StartTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt StopTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt InterfaceInfoTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt InterfaceLengthInfoTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt NumberOfInterfacesInfoTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt StartupPriorityInfoTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt StateInfoTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt OwnerTestL( TUsbObexClassControllerTestResult& aTestResult ); - TInt CompareTestL( TUsbObexClassControllerTestResult& aTestResult ); - - public: // Data - // ?one_line_short_description_of_data - //?data_declaration; - - protected: // Data - // ?one_line_short_description_of_data - //?data_declaration; - - private: // Data - - // ?one_line_short_description_of_data - //?data_declaration; - - CUsbClassControllerPlugIn* iUsbClassControllerPlugIn; - CActiveScheduler* iScheduler; - TRequestStatus iRequestStatus; - TUsbServiceState iUsbServiceState; - - // Reserved pointer for future extension - //TAny* iReserved; - - public: // Friend classes - //?friend_class_declaration; - protected: // Friend classes - //?friend_class_declaration; - private: // Friend classes - //?friend_class_declaration; - - }; - -#endif // USBOBEXCLASSCONTROLLERTEST_H - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/init/UsbObexClassControllerTest_ats.ini --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/init/UsbObexClassControllerTest_ats.ini Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,218 +0,0 @@ -# -# This is STIF initialization file -# Comment lines start with '#'-character. -# See STIF TestFramework users guide.doc for instructions - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set following test engine settings: -# - Set Test Reporting mode. TestReportMode's possible values are: -# + 'Summary': Summary of the tested test cases. -# + 'Environment': Hardware and software info. -# + 'TestCases': Test case report. -# + 'FullReport': Set of all above ones. -# + Example 'TestReportMode= Summary TestCases' -# -# - CreateTestReport setting controls report creation mode -# + YES, Test report will created. -# + NO, No Test report. -# -# - File path indicates the base path of the test report. -# - File name indicates the name of the test report. -# -# - File format indicates the type of the test report. -# + TXT, Test report file will be txt type, for example 'TestReport.txt'. -# + HTML, Test report will be html type, for example 'TestReport.html'. -# + XML, Test report will be xml type, for example 'TestReport.xml'. -# Note, that xml format is available only when output is set to FILE. -# -# - File output indicates output source of the test report. -# + FILE, Test report logging to file. -# + RDEBUG, Test report logging to using rdebug. -# -# - File Creation Mode indicates test report overwriting if file exist. -# + OVERWRITE, Overwrites if the Test report file exist. -# + APPEND, Continue logging after the old Test report information if -# report exist. -# - Sets a device reset module's dll name(Reboot). -# + If Nokia specific reset module is not available or it is not correct one -# StifHWResetStub module may use as a template for user specific reset -# module. -# - Sets STIF test measurement disable options. e.g. pluging1 and pluging2 disablation -# DisableMeasurement= stifmeasurementplugin01 stifmeasurementplugin02 -# - -[Engine_Defaults] - -TestReportMode= FullReport # Possible values are: 'Empty', 'Summary', 'Environment', - 'TestCases' or 'FullReport' - -CreateTestReport= YES # Possible values: YES or NO - -TestReportFilePath= e:\testing\logs\ -TestReportFileName= UsbObexClassControllerTest_TestReport - -TestReportFormat= TXT # Possible values: TXT, HTML or XML -TestReportOutput= FILE # Possible values: FILE or RDEBUG -TestReportFileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -DeviceResetDllName= StifResetForNokia.dll # e.g. 'StifHWResetStub.dll' for user specific reseting - -DisableMeasurement= stifmeasurementdisablenone # Possible values are: - # 'stifmeasurementdisablenone', 'stifmeasurementdisableall' - # 'stifmeasurementplugin01', 'stifmeasurementplugin02', - # 'stifmeasurementplugin03', 'stifmeasurementplugin04', - # 'stifmeasurementplugin05' or 'stifbappeaprofiler' - -Timeout= 0 # Default timeout value for each test case. In milliseconds -UITestingSupport= YES # Possible values: YES or NO -#SeparateProcesses= YES # Possible values: YES or NO (default: NO) -[End_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Module configurations start -# Modules are added between module tags -# tags. Module name is specified after ModuleName= tag, like -# ModuleName= UsbObexClassControllerTestUsbObexClassControllerTestUsbObexClassControllerTest -# Modules might have initialisation file, specified as -# IniFile= c:\testframework\YYYYYY -# Modules might have several configuration files, like -# TestCaseFile= c:\testframework\NormalCases.txt -# TestCaseFile= c:\testframework\SmokeCases.txt -# TestCaseFile= c:\testframework\ManualCases.txt - -# (TestCaseFile is synonym for old term ConfigFile) - -# Following case specifies demo module settings. Demo module -# does not read any settings from file, so tags -# IniFile and TestCaseFile are not used. -# In the simplest case it is enough to specify only the -# name of the test module when adding new test module - -[New_Module] -ModuleName= testscripter -TestCaseFile= e:\testing\conf\UsbObexClassControllerTest.cfg -[End_Module] - - -# Load testmoduleUsbObexClassControllerTest, optionally with initialization file and/or test case files -#[New_Module] -#ModuleName= testmodulexxx - -#TestModuleUsbObexClassControllerTest used initialization file -#IniFile= c:\testframework\init.txt - -#TestModuleUsbObexClassControllerTest used configuration file(s) -#TestCaseFile= c:\testframework\testcases1.cfg -#TestCaseFile= c:\testframework\testcases2.cfg -#TestCaseFile= c:\testframework\manualtestcases.cfg - -#[End_Module] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set STIF logging overwrite parameters for Logger. -# Hardware and emulator environment logging path and styles can -# be configured from here to overwrite the Logger's implemented values. -# -# Settings description: -# - Indicates option for creation log directory/directories. If log directory/directories -# is/are not created by user they will make by software. -# + YES, Create log directory/directories if not allready exist. -# + NO, Log directory/directories not created. Only created one is used. -# -# - Overwrite emulator path setting. -# + Example: If 'EmulatorBasePath= C:\LOGS\TestFramework\' and in code is defined -# Logger's path 'D:\\LOGS\\Module\\' with those definition the path -# will be 'C:\LOGS\TestFramework\LOGS\Module\' -# -# - Overwrite emulator's logging format. -# + TXT, Log file(s) will be txt type(s), for example 'Module.txt'. -# + HTML, Log file(s) will be html type(s), for example 'Module.html'. -# -# - Overwrited emulator logging output source. -# + FILE, Logging to file(s). -# + RDEBUG, Logging to using rdebug(s). -# -# - Overwrite hardware path setting (Same description as above in emulator path). -# - Overwrite hardware's logging format(Same description as above in emulator format). -# - Overwrite hardware's logging output source(Same description as above in emulator output). -# -# - File Creation Mode indicates file overwriting if file exist. -# + OVERWRITE, Overwrites if file(s) exist. -# + APPEND, Continue logging after the old logging information if file(s) exist. -# -# - Will thread id include to the log filename. -# + YES, Thread id to log file(s) name, Example filename 'Module_b9.txt'. -# + NO, No thread id to log file(s), Example filename 'Module.txt'. -# -# - Will time stamps include the to log file. -# + YES, Time stamp added to each line in log file(s). Time stamp is -# for example'12.Nov.2003 115958 LOGGING INFO' -# + NO, No time stamp(s). -# -# - Will line breaks include to the log file. -# + YES, Each logging event includes line break and next log event is in own line. -# + NO, No line break(s). -# -# - Will event ranking include to the log file. -# + YES, Event ranking number added to each line in log file(s). Ranking number -# depends on environment's tics, for example(includes time stamp also) -# '012 12.Nov.2003 115958 LOGGING INFO' -# + NO, No event ranking. -# -# - Will write log file in unicode format. -# + YES, Log file will be written in unicode format -# + NO, Log will be written as normal, not unicode, file. -# - -[Logger_Defaults] - -#NOTE: If you want to set Logger using next setting(s) remove comment(s)'#' -#NOTE: TestEngine and TestServer logging settings cannot change here - -#CreateLogDirectories= YES # Possible values: YES or NO - -#EmulatorBasePath= C:\LOGS\TestFramework\ -#EmulatorFormat= HTML # Possible values: TXT or HTML -#EmulatorOutput= FILE # Possible values: FILE or RDEBUG - -#HardwareBasePath= D:\LOGS\TestFramework\ -#HardwareFormat= HTML # Possible values: TXT or HTML -#HardwareOutput= FILE # Possible values: FILE or RDEBUG - -#FileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -#ThreadIdToLogFile= YES # Possible values: YES or NO -#WithTimeStamp= YES # Possible values: YES or NO -#WithLineBreak= YES # Possible values: YES or NO -#WithEventRanking= YES # Possible values: YES or NO - -#FileUnicode= YES # Possible values: YES or NO -#AddTestCaseTitle= YES # Possible values: YES or NO -[End_Logger_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set filters to be used by ConsoleUI. -# If you want to use filter with ConsoleUI, simply remove comments -# from section below and provide valid filter entries. -# Each filter line has to start with "filter= " keyword. -# Filter can contain special wildcard characters: -# * which stands for none or any literal; -# ? which stands for single character. -# Filters are not case-sensitive. - -#[Filters] -#filter= *math* -#filter= *radio* -#[End_Filters] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - -# End of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/init/UsbObexClassControllerTest_phone.ini --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/init/UsbObexClassControllerTest_phone.ini Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,218 +0,0 @@ -# -# This is STIF initialization file -# Comment lines start with '#'-character. -# See STIF TestFramework users guide.doc for instructions - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set following test engine settings: -# - Set Test Reporting mode. TestReportMode's possible values are: -# + 'Summary': Summary of the tested test cases. -# + 'Environment': Hardware and software info. -# + 'TestCases': Test case report. -# + 'FullReport': Set of all above ones. -# + Example 'TestReportMode= Summary TestCases' -# -# - CreateTestReport setting controls report creation mode -# + YES, Test report will created. -# + NO, No Test report. -# -# - File path indicates the base path of the test report. -# - File name indicates the name of the test report. -# -# - File format indicates the type of the test report. -# + TXT, Test report file will be txt type, for example 'TestReport.txt'. -# + HTML, Test report will be html type, for example 'TestReport.html'. -# + XML, Test report will be xml type, for example 'TestReport.xml'. -# Note, that xml format is available only when output is set to FILE. -# -# - File output indicates output source of the test report. -# + FILE, Test report logging to file. -# + RDEBUG, Test report logging to using rdebug. -# -# - File Creation Mode indicates test report overwriting if file exist. -# + OVERWRITE, Overwrites if the Test report file exist. -# + APPEND, Continue logging after the old Test report information if -# report exist. -# - Sets a device reset module's dll name(Reboot). -# + If Nokia specific reset module is not available or it is not correct one -# StifHWResetStub module may use as a template for user specific reset -# module. -# - Sets STIF test measurement disable options. e.g. pluging1 and pluging2 disablation -# DisableMeasurement= stifmeasurementplugin01 stifmeasurementplugin02 -# - -[Engine_Defaults] - -TestReportMode= FullReport # Possible values are: 'Empty', 'Summary', 'Environment', - 'TestCases' or 'FullReport' - -CreateTestReport= YES # Possible values: YES or NO - -TestReportFilePath= c:\logs\testframework\UsbObexClassControllerTest\ -TestReportFileName= testreport - -TestReportFormat= TXT # Possible values: TXT, HTML or XML -TestReportOutput= FILE # Possible values: FILE or RDEBUG -TestReportFileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -DeviceResetDllName= StifResetForNokia.dll # e.g. 'StifHWResetStub.dll' for user specific reseting - -DisableMeasurement= stifmeasurementdisablenone # Possible values are: - # 'stifmeasurementdisablenone', 'stifmeasurementdisableall' - # 'stifmeasurementplugin01', 'stifmeasurementplugin02', - # 'stifmeasurementplugin03', 'stifmeasurementplugin04', - # 'stifmeasurementplugin05' or 'stifbappeaprofiler' - -Timeout= 0 # Default timeout value for each test case. In milliseconds -UITestingSupport= YES # Possible values: YES or NO -#SeparateProcesses= YES # Possible values: YES or NO (default: NO) -[End_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Module configurations start -# Modules are added between module tags -# tags. Module name is specified after ModuleName= tag, like -# ModuleName= UsbObexClassControllerTestUsbObexClassControllerTestUsbObexClassControllerTest -# Modules might have initialisation file, specified as -# IniFile= c:\testframework\YYYYYY -# Modules might have several configuration files, like -# TestCaseFile= c:\testframework\NormalCases.txt -# TestCaseFile= c:\testframework\SmokeCases.txt -# TestCaseFile= c:\testframework\ManualCases.txt - -# (TestCaseFile is synonym for old term ConfigFile) - -# Following case specifies demo module settings. Demo module -# does not read any settings from file, so tags -# IniFile and TestCaseFile are not used. -# In the simplest case it is enough to specify only the -# name of the test module when adding new test module - -[New_Module] -ModuleName= testscripter -TestCaseFile= c:\testframework\UsbObexClassControllerTest.cfg -[End_Module] - - -# Load testmoduleUsbObexClassControllerTest, optionally with initialization file and/or test case files -#[New_Module] -#ModuleName= testmodulexxx - -#TestModuleUsbObexClassControllerTest used initialization file -#IniFile= c:\testframework\init.txt - -#TestModuleUsbObexClassControllerTest used configuration file(s) -#TestCaseFile= c:\testframework\testcases1.cfg -#TestCaseFile= c:\testframework\testcases2.cfg -#TestCaseFile= c:\testframework\manualtestcases.cfg - -#[End_Module] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set STIF logging overwrite parameters for Logger. -# Hardware and emulator environment logging path and styles can -# be configured from here to overwrite the Logger's implemented values. -# -# Settings description: -# - Indicates option for creation log directory/directories. If log directory/directories -# is/are not created by user they will make by software. -# + YES, Create log directory/directories if not allready exist. -# + NO, Log directory/directories not created. Only created one is used. -# -# - Overwrite emulator path setting. -# + Example: If 'EmulatorBasePath= C:\LOGS\TestFramework\' and in code is defined -# Logger's path 'D:\\LOGS\\Module\\' with those definition the path -# will be 'C:\LOGS\TestFramework\LOGS\Module\' -# -# - Overwrite emulator's logging format. -# + TXT, Log file(s) will be txt type(s), for example 'Module.txt'. -# + HTML, Log file(s) will be html type(s), for example 'Module.html'. -# -# - Overwrited emulator logging output source. -# + FILE, Logging to file(s). -# + RDEBUG, Logging to using rdebug(s). -# -# - Overwrite hardware path setting (Same description as above in emulator path). -# - Overwrite hardware's logging format(Same description as above in emulator format). -# - Overwrite hardware's logging output source(Same description as above in emulator output). -# -# - File Creation Mode indicates file overwriting if file exist. -# + OVERWRITE, Overwrites if file(s) exist. -# + APPEND, Continue logging after the old logging information if file(s) exist. -# -# - Will thread id include to the log filename. -# + YES, Thread id to log file(s) name, Example filename 'Module_b9.txt'. -# + NO, No thread id to log file(s), Example filename 'Module.txt'. -# -# - Will time stamps include the to log file. -# + YES, Time stamp added to each line in log file(s). Time stamp is -# for example'12.Nov.2003 115958 LOGGING INFO' -# + NO, No time stamp(s). -# -# - Will line breaks include to the log file. -# + YES, Each logging event includes line break and next log event is in own line. -# + NO, No line break(s). -# -# - Will event ranking include to the log file. -# + YES, Event ranking number added to each line in log file(s). Ranking number -# depends on environment's tics, for example(includes time stamp also) -# '012 12.Nov.2003 115958 LOGGING INFO' -# + NO, No event ranking. -# -# - Will write log file in unicode format. -# + YES, Log file will be written in unicode format -# + NO, Log will be written as normal, not unicode, file. -# - -[Logger_Defaults] - -#NOTE: If you want to set Logger using next setting(s) remove comment(s)'#' -#NOTE: TestEngine and TestServer logging settings cannot change here - -#CreateLogDirectories= YES # Possible values: YES or NO - -#EmulatorBasePath= C:\LOGS\TestFramework\ -#EmulatorFormat= HTML # Possible values: TXT or HTML -#EmulatorOutput= FILE # Possible values: FILE or RDEBUG - -#HardwareBasePath= D:\LOGS\TestFramework\ -#HardwareFormat= HTML # Possible values: TXT or HTML -#HardwareOutput= FILE # Possible values: FILE or RDEBUG - -#FileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -#ThreadIdToLogFile= YES # Possible values: YES or NO -#WithTimeStamp= YES # Possible values: YES or NO -#WithLineBreak= YES # Possible values: YES or NO -#WithEventRanking= YES # Possible values: YES or NO - -#FileUnicode= YES # Possible values: YES or NO -#AddTestCaseTitle= YES # Possible values: YES or NO -[End_Logger_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set filters to be used by ConsoleUI. -# If you want to use filter with ConsoleUI, simply remove comments -# from section below and provide valid filter entries. -# Each filter line has to start with "filter= " keyword. -# Filter can contain special wildcard characters: -# * which stands for none or any literal; -# ? which stands for single character. -# Filters are not case-sensitive. - -#[Filters] -#filter= *math* -#filter= *radio* -#[End_Filters] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - -# End of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/USBObexApiTestActiveObject.cpp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/USBObexApiTestActiveObject.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,107 +0,0 @@ -/* -* 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 "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: -* -*/ - -#include "USBObexApiTestActiveObject.h" - -// ----------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::CUSBObexApiTestActiveObject -// C++ default constructor can NOT contain any code, that -// might leave. -// ----------------------------------------------------------------------------- -// -CUSBObexApiTestActiveObject::CUSBObexApiTestActiveObject( CStifLogger* aLog, - CUsbClassControllerPlugIn* aUsbClassControllerPlugIn ) : - CActive( EPriorityStandard ) - { - iUsbClassControllerPlugIn = aUsbClassControllerPlugIn; - iLog = aLog; - } - -// Destructor -CUSBObexApiTestActiveObject::~CUSBObexApiTestActiveObject() - { - Cancel(); - } - -// --------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::RunL -// --------------------------------------------------------------------------- -// -void CUSBObexApiTestActiveObject::RunL() - { - iLog->Log( _L("ActiveTestObject::RunL")); - CActiveScheduler::Stop(); - iLog->Log( _L("ActiveScheduler Stopped")); - iUsbServiceState = iUsbClassControllerPlugIn -> State(); - } - -// ----------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::NewL -// Two-phased constructor. -// ----------------------------------------------------------------------------- -// -CUSBObexApiTestActiveObject* CUSBObexApiTestActiveObject::NewL( - CStifLogger* aLog, CUsbClassControllerPlugIn* aUsbClassControllerPlugIn ) - { - CUSBObexApiTestActiveObject* self = new ( ELeave )CUSBObexApiTestActiveObject( aLog, aUsbClassControllerPlugIn ); - CleanupStack::PushL( self ); - self->ConstructL(); - CleanupStack::Pop( self ); - return self; - } - -// ----------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::ConstructL -// Symbian 2nd phase constructor can leave. -// ----------------------------------------------------------------------------- -// -void CUSBObexApiTestActiveObject::ConstructL() - { - CActiveScheduler::Add( this ); - } - -// --------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::DoCancel -// --------------------------------------------------------------------------- -// -void CUSBObexApiTestActiveObject::DoCancel() - { - iLog->Log( _L("ActiveTestObject::DoCancel")); - } - -// --------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::Start -// --------------------------------------------------------------------------- -// -void CUSBObexApiTestActiveObject::Start() - { - iUsbClassControllerPlugIn -> Start( iStatus ); - SetActive(); - iLog->Log( _L("Obex Controller Started")); - } - -// --------------------------------------------------------------------------- -// CUSBObexApiTestActiveObject::Stop -// --------------------------------------------------------------------------- -// -void CUSBObexApiTestActiveObject::Stop() - { - iUsbClassControllerPlugIn -> Stop( iStatus ); - SetActive(); - iLog->Log( _L("Obex Controller Stopped")); - } - diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTest.cpp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTest.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,202 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - - -// INCLUDE FILES -#include -#include "UsbObexClassControllerTest.h" -#include - -// EXTERNAL DATA STRUCTURES -//extern ?external_data; - -// EXTERNAL FUNCTION PROTOTYPES -//extern ?external_function( ?arg_type,?arg_type ); - -// CONSTANTS -//const ?type ?constant_var = ?constant; - -// MACROS -//#define ?macro ?macro_def - -// LOCAL CONSTANTS AND MACROS -//const ?type ?constant_var = ?constant; -//#define ?macro_name ?macro_def - -// MODULE DATA STRUCTURES -//enum ?declaration -//typedef ?declaration - -// LOCAL FUNCTION PROTOTYPES -//?type ?function_name( ?arg_type, ?arg_type ); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; - -// ============================= LOCAL FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// ?function_name ?description. -// ?description -// Returns: ?value_1: ?description -// ?value_n: ?description_line1 -// ?description_line2 -// ----------------------------------------------------------------------------- -// -/* -?type ?function_name( - ?arg_type arg, // ?description - ?arg_type arg) // ?description - { - - ?code // ?comment - - // ?comment - ?code - } -*/ - -// ============================ MEMBER FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::CUsbObexClassControllerTest -// C++ default constructor can NOT contain any code, that -// might leave. -// ----------------------------------------------------------------------------- -// -CUsbObexClassControllerTest::CUsbObexClassControllerTest( - CTestModuleIf& aTestModuleIf ): - CScriptBase( aTestModuleIf ) - { - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::ConstructL -// Symbian 2nd phase constructor can leave. -// ----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::ConstructL() - { - //Read logger settings to check whether test case name is to be - //appended to log file name. - RSettingServer settingServer; - TInt ret = settingServer.Connect(); - if(ret != KErrNone) - { - User::Leave(ret); - } - // Struct to StifLogger settigs. - TLoggerSettings loggerSettings; - // Parse StifLogger defaults from STIF initialization file. - ret = settingServer.GetLoggerSettings(loggerSettings); - if(ret != KErrNone) - { - User::Leave(ret); - } - // Close Setting server session - settingServer.Close(); - - TFileName logFileName; - - if(loggerSettings.iAddTestCaseTitle) - { - TName title; - TestModuleIf().GetTestCaseTitleL(title); - logFileName.Format(KUsbObexClassControllerTestLogFileWithTitle, &title); - } - else - { - logFileName.Copy(KUsbObexClassControllerTestLogFile); - } - - iLog = CStifLogger::NewL( KUsbObexClassControllerTestLogPath, - logFileName, - CStifLogger::ETxt, - CStifLogger::EFile, - EFalse ); - - SendTestClassVersion(); - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::NewL -// Two-phased constructor. -// ----------------------------------------------------------------------------- -// -CUsbObexClassControllerTest* CUsbObexClassControllerTest::NewL( - CTestModuleIf& aTestModuleIf ) - { - CUsbObexClassControllerTest* self = new (ELeave) CUsbObexClassControllerTest( aTestModuleIf ); - - CleanupStack::PushL( self ); - self->ConstructL(); - CleanupStack::Pop(); - - return self; - - } - -// Destructor -CUsbObexClassControllerTest::~CUsbObexClassControllerTest() - { - - // Delete resources allocated from test methods - Delete(); - - // Delete logger - delete iLog; - - } - -//----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::SendTestClassVersion -// Method used to send version of test class -//----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::SendTestClassVersion() - { - TVersion moduleVersion; - moduleVersion.iMajor = TEST_CLASS_VERSION_MAJOR; - moduleVersion.iMinor = TEST_CLASS_VERSION_MINOR; - moduleVersion.iBuild = TEST_CLASS_VERSION_BUILD; - - TFileName moduleName; - moduleName = _L("UsbObexClassControllerTest.dll"); - - TBool newVersionOfMethod = ETrue; - TestModuleIf().SendTestModuleVersion(moduleVersion, moduleName, newVersionOfMethod); - } - -// ========================== OTHER EXPORTED FUNCTIONS ========================= - -// ----------------------------------------------------------------------------- -// LibEntryL is a polymorphic Dll entry point. -// Returns: CScriptBase: New CScriptBase derived object -// ----------------------------------------------------------------------------- -// -EXPORT_C CScriptBase* LibEntryL( - CTestModuleIf& aTestModuleIf ) // Backpointer to STIF Test Framework - { - - return ( CScriptBase* ) CUsbObexClassControllerTest::NewL( aTestModuleIf ); - - } - - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTestBlocks.cpp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTestBlocks.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,681 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - - -// [INCLUDE FILES] - do not remove -#include -#include -#include -#include "UsbObexClassControllerTest.h" - -// EXTERNAL DATA STRUCTURES -//extern ?external_data; - -// EXTERNAL FUNCTION PROTOTYPES -//extern ?external_function( ?arg_type,?arg_type ); - -// CONSTANTS -//const ?type ?constant_var = ?constant; -const TUid KCSrcsInterfaceUid = {0x101F7C8C}; -const TInt KObexNumInterfaces = 2; - -// MACROS -//#define ?macro ?macro_def - -// LOCAL CONSTANTS AND MACROS -//const ?type ?constant_var = ?constant; -//#define ?macro_name ?macro_def - -// MODULE DATA STRUCTURES -//enum ?declaration -//typedef ?declaration - -// LOCAL FUNCTION PROTOTYPES -//?type ?function_name( ?arg_type, ?arg_type ); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; - -// ============================= LOCAL FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// ?function_name ?description. -// ?description -// Returns: ?value_1: ?description -// ?value_n: ?description_line1 -// ?description_line2 -// ----------------------------------------------------------------------------- -// -/* -?type ?function_name( - ?arg_type arg, // ?description - ?arg_type arg) // ?description - { - - ?code // ?comment - - // ?comment - ?code - } -*/ - -// ============================ MEMBER FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::Delete -// Delete here all resources allocated and opened from test methods. -// Called from destructor. -// ----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::Delete() - { - - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::RunMethodL -// Run specified method. Contains also table of test mothods and their names. -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::RunMethodL( - CStifItemParser& aItem ) - { - - static TStifFunctionInfo const KFunctions[] = - { - //ADD NEW ENTRY HERE - // [test cases entries] - Do not remove - ENTRY( "ExecuteApiTest", CUsbObexClassControllerTest::ExecuteApiTest ), - ENTRY( "ExecuteModuleTest", CUsbObexClassControllerTest::ExecuteModuleTest ), - ENTRY( "ExecuteBranchTest", CUsbObexClassControllerTest::ExecuteBranchTest ), - }; - - const TInt count = sizeof( KFunctions ) / - sizeof( TStifFunctionInfo ); - - return RunInternalL( KFunctions, count, aItem ); - - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::ExecuteApiTest -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::ExecuteApiTest( CStifItemParser& aItem ) - { - STIF_LOG( "[STIF_LOG] >>>ExecuteApiTest" ); - - TInt res; - TUsbObexClassControllerTestResult testResult = ETestCaseFailed; - TPtrC apiTestName( KNullDesC ); - - res = aItem.GetString( _L( "ExecuteApiTest" ), apiTestName ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "GetString failed with value: %d" ), res ); - return res; - } - - TRAP( res, DoExecuteApiTestL( apiTestName, testResult ) ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "DoExecuteApiTestL error: %d"), res ); - return res; - } - - STIF_ASSERT_EQUALS( ETestCasePassed, testResult ); - STIF_LOG( "[STIF_LOG] Test case passed" ); - STIF_LOG( "[STIF_LOG] <<>>DoExecuteApiTestL" ); - if ( !aApiTestName.Compare( _L( "ExampleApiTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - ExampleApiTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "InitializationTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - InitializationTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "StartTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - StartTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "StopTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - StopTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "InterfaceInfoTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - InterfaceInfoTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "InterfaceLengthInfoTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - InterfaceLengthInfoTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "NumberOfInterfacesInfoTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - NumberOfInterfacesInfoTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "StartupPriorityInfoTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - StartupPriorityInfoTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "StateInfoTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - StateInfoTestL( aTestResult ); - } - else if ( !aApiTestName.Compare( _L( "OwnerTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Api test type: ExampleApiTest" ); - OwnerTestL( aTestResult ); - } - else - { - STIF_LOG( "[STIF_LOG] Api test type: not found" ); - User::Leave( KErrNotFound ); - } - STIF_LOG( "[STIF_LOG] <<>>ExampleApiTestL" ); - - aTestResult = ETestCasePassed; - - STIF_LOG( "[STIF_LOG] <<>>ExecuteModuleTest" ); - - TInt res; - TUsbObexClassControllerTestResult testResult; - TPtrC moduleTestName( KNullDesC ); - - res = aItem.GetString( _L( "ExecuteModuleTest" ), moduleTestName ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "GetString failed with value: %d" ), res ); - return res; - } - - TRAP( res, DoExecuteModuleTestL( moduleTestName, testResult ) ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "DoExecuteModuleTestL error: %d"), res ); - return res; - } - - STIF_ASSERT_EQUALS( ETestCasePassed, testResult ); - STIF_LOG( "[STIF_LOG] Test case passed" ); - STIF_LOG( "[STIF_LOG] <<>>DoExecuteModuleTestL" ); - if ( !aModuleTestName.Compare( _L( "ExampleModuleTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Module test type: ExampleModuleTest" ); - ExampleModuleTestL( aTestResult ); - } - else - { - STIF_LOG( "[STIF_LOG] Module test type: not found" ); - User::Leave( KErrNotFound ); - } - STIF_LOG( "[STIF_LOG] <<>>ExampleModuleTestL" ); - - aTestResult = ETestCasePassed; - - STIF_LOG( "[STIF_LOG] <<>>ExecuteBranchTest" ); - - TInt res; - TUsbObexClassControllerTestResult testResult; - TPtrC branchTestName( KNullDesC ); - - res = aItem.GetString( _L( "ExecuteBranchTest" ), branchTestName ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "GetString failed with value: %d" ), res ); - return res; - } - - TRAP( res, DoExecuteBranchTestL( branchTestName, testResult ) ); - if ( res != KErrNone ) - { - iLog -> Log( _L( "DoExecuteBranchTestL error: %d"), res ); - return res; - } - - STIF_ASSERT_EQUALS( ETestCasePassed, testResult ); - STIF_LOG( "[STIF_LOG] Test case passed" ); - STIF_LOG( "[STIF_LOG] <<>>DoExecuteBranchTestL" ); - if ( !aBranchTestName.Compare( _L( "ExampleBranchTest" ) ) ) - { - STIF_LOG( "[STIF_LOG] Branch test type: ExampleBranchTest" ); - ExampleBranchTestL( aTestResult ); - } - else - { - STIF_LOG( "[STIF_LOG] Branch test type: not found" ); - User::Leave( KErrNotFound ); - } - STIF_LOG( "[STIF_LOG] <<>>ExampleBranchTestL" ); - - aTestResult = ETestCasePassed; - - STIF_LOG( "[STIF_LOG] <<Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::StartTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::StartTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - iUsbServiceState = EUsbServiceStarted; - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - iLog->Log( _L("UsbServiceState = %d, expected %d"), - iUsbServiceState, iUsbClassControllerPlugIn -> State()); - STIF_ASSERT_EQUALS( iUsbServiceState, iUsbClassControllerPlugIn -> State() ); - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::StopTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::StopTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - iUsbServiceState = EUsbServiceIdle; - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - activeTestObject -> Stop(); - CActiveScheduler::Start(); - iLog->Log( _L("UsbServiceState = %d, expected %d"), - iUsbServiceState, iUsbClassControllerPlugIn -> State()); - STIF_ASSERT_EQUALS( iUsbServiceState, iUsbClassControllerPlugIn -> State() ); - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::InterfaceInfoTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::InterfaceInfoTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - TUsbDescriptor aDescriptorInfo; - RImplInfoPtrArray implInfoArray; - CleanupClosePushL(implInfoArray); - TEComResolverParams resolverParams; - TInt numberOfInterfaces; - - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - iUsbClassControllerPlugIn -> GetDescriptorInfo( aDescriptorInfo ); - resolverParams.SetDataType( KSrcsTransportUSB ); - resolverParams.SetWildcardMatch( EFalse ); - REComSession::ListImplementationsL( KCSrcsInterfaceUid, resolverParams, implInfoArray ); - numberOfInterfaces = implInfoArray.Count() * KObexNumInterfaces; - - iLog->Log( _L("Number of interfaces = %d, expected %d"), - numberOfInterfaces, aDescriptorInfo.iNumInterfaces); - STIF_ASSERT_EQUALS( numberOfInterfaces, aDescriptorInfo.iNumInterfaces ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - CleanupStack::PopAndDestroy(&implInfoArray); - - // Case was executed - iLog->Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::InterfaceLengthInfoTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::InterfaceLengthInfoTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - TUsbDescriptor aDescriptorInfo; - RImplInfoPtrArray implInfoArray; - CleanupClosePushL(implInfoArray); - TEComResolverParams resolverParams; - TInt interfaceLength = 0; - - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - iUsbClassControllerPlugIn -> GetDescriptorInfo( aDescriptorInfo ); - resolverParams.SetDataType( KSrcsTransportUSB ); - resolverParams.SetWildcardMatch( EFalse ); - REComSession::ListImplementationsL( KCSrcsInterfaceUid, resolverParams, implInfoArray ); - - iLog->Log( _L("Interface Length = %d, expected %d"), - interfaceLength, aDescriptorInfo.iLength); - STIF_ASSERT_EQUALS( interfaceLength, aDescriptorInfo.iLength ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - CleanupStack::PopAndDestroy(&implInfoArray); - - // Case was executed - iLog->Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::NumberOfInterfacesInfoTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::NumberOfInterfacesInfoTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - TUsbDescriptor aDescriptorInfo; - RImplInfoPtrArray implInfoArray; - CleanupClosePushL(implInfoArray); - TEComResolverParams resolverParams; - TInt interfaceLength = 0; - - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - iUsbClassControllerPlugIn -> GetDescriptorInfo( aDescriptorInfo ); - resolverParams.SetDataType( KSrcsTransportUSB ); - resolverParams.SetWildcardMatch( EFalse ); - REComSession::ListImplementationsL( KCSrcsInterfaceUid, resolverParams, implInfoArray ); - - iLog->Log( _L("Number of Interfaces this class controller is responsible for = %d, expected %d"), - interfaceLength, aDescriptorInfo.iNumInterfaces); - STIF_ASSERT_EQUALS( interfaceLength, aDescriptorInfo.iLength ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - CleanupStack::PopAndDestroy(&implInfoArray); - - // Case was executed - iLog->Log( _L("Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::StartupPriorityInfoTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::StartupPriorityInfoTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - TInt priority = 0; - - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - priority = iUsbClassControllerPlugIn -> StartupPriority(); - - iLog->Log( _L("StartupPriorityInfoTestL:> Priority = %d "),priority ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("StartupPriorityInfoTestL:> Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::StateInfoTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::StateInfoTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - TUsbServiceState state; - - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - state = iUsbClassControllerPlugIn -> State(); - - iLog->Log( _L("StateTestL:> State = 0x%x "), state ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("StateInfoTestL:> Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::OwnerTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::OwnerTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - InitializeTestObjectL(); - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - (iUsbClassControllerPlugIn -> Owner()).UccnGetClassControllerIteratorL(); - - (iUsbClassControllerPlugIn -> Owner()).UccnError( KErrNone ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("OwnerTestL:> Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::CompareTestL -// ----------------------------------------------------------------------------- -// -TInt CUsbObexClassControllerTest::CompareTestL( TUsbObexClassControllerTestResult& aTestResult ) - { - InitializeTestObjectL(); - - CUSBObexApiTestActiveObject* activeTestObject = - CUSBObexApiTestActiveObject::NewL( iLog, iUsbClassControllerPlugIn ); - activeTestObject -> Start(); - CActiveScheduler::Start(); - - //result = iUsbClassControllerPlugIn -> Compare( this, iUsbClassControllerPlugIn ); - //iLog->Log( _L("CompareTestL:> Comparition Result = %d "),result ); - - DeleteTestObject(); - activeTestObject -> Cancel(); - - // Case was executed - iLog->Log( _L("CompareTestL:> Test Case Passed")); - aTestResult = ETestCasePassed; - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::InitializeTestObjectL -// ----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::InitializeTestObjectL() - { - iUsbClassControllerPlugIn = CUsbClassControllerPlugIn::NewL( TUid::Uid( 0x10281F2A ), *this); - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::DeleteTestObject -// ----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::DeleteTestObject() - { - delete iUsbClassControllerPlugIn; - iUsbClassControllerPlugIn = NULL; - REComSession::FinalClose(); - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::UccnGetClassControllerIteratorL -// ----------------------------------------------------------------------------- -// -CUsbClassControllerIterator* CUsbObexClassControllerTest::UccnGetClassControllerIteratorL() - { - iLog->Log( _L("get class controller iterator")); - return (CUsbClassControllerIterator *)NULL; - } - -// ----------------------------------------------------------------------------- -// CUsbObexClassControllerTest::UccnError -// ----------------------------------------------------------------------------- -// -void CUsbObexClassControllerTest::UccnError( TInt aError ) - { - iLog->Log( _L("class controller iterator error: %d"), aError ); - } -// ========================== OTHER EXPORTED FUNCTIONS ========================= -// None - -// [End of File] - Do not remove diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTest_exe.cpp --- a/usbclasses/usbobexclasscontroller/tsrc/UsbObexClassControllerTest/src/UsbObexClassControllerTest_exe.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,66 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - -// INCLUDE FILES -#include -#include -#include -// EXTERNAL DATA STRUCTURES - -// EXTERNAL FUNCTION PROTOTYPES - -// ================= OTHER EXPORTED FUNCTIONS ================================= - -/* -------------------------------------------------------------------------------- - - Class: - - - Method: E32Main - - Description: - - Parameters: None - - Return Values: TInt: Symbian error code - - Errors/Exceptions: None - - Status: Draft - -------------------------------------------------------------------------------- -*/ -GLDEF_C TInt E32Main() - { - _LIT( KProcessMsgStart, "New process starting" ); - RDebug::Print( KProcessMsgStart ); - - - // This starts a new session that get capabilites that is used in - // UsbObexClassControllerTest_exe.mmp file. - TInt r = StartSession(); - - _LIT( KProcessMsgEnd, "New process ends" ); - RDebug::Print( KProcessMsgEnd ); - - return r; - - } - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classcontroller/inc/usbmscfileclasscontroller.h --- a/usbclasses/usbphoneasmodem/classcontroller/inc/usbmscfileclasscontroller.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classcontroller/inc/usbmscfileclasscontroller.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Adheres to the UsbMan USB Class API and talks to mass storage file system // // - -/** - @file - @internalTechnology - Adheres to the UsbMan USB Class API and talks to mass storage file system - */ - #ifndef USBMSCLASSCONTROLLER_H #define USBMSCLASSCONTROLLER_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontroller.cpp --- a/usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontroller.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontroller.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Adheres to the UsbMan USB Class Controller API and talks to mass storage file server // // - -/** - @file - Adheres to the UsbMan USB Class Controller API and talks to mass storage - file server - */ - #include #include #include diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontrollerimp.cpp --- a/usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontrollerimp.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classcontroller/src/usbmscfileclasscontrollerimp.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,20 +10,15 @@ // // Contributors: // -// Description: +// Description: Defines the implementation collection for the mass storage class controller. // // -/** - @file - Defines the implementation collection for the mass storage class controller. - */ - #include #include #include #include -#include "UsbMscFileClassController.h" +#include "usbmscfileclasscontroller.h" #include "usbmscfileuids.hrh" // Define the private interface UIDs diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.h --- a/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,18 +10,10 @@ // // Contributors: // -// Description: -// +// Description: RUsbMscFile Client side header +// Implements the Symbian OS USB mass storage server RUsbMscFile API // - -/** - @file - @internalTechnology - RUsbMscFile Client side header - Implements the Symbian OS USB mass storage server RUsbMscFile API - */ - #ifndef USBMSCFILE_H #define USBMSCFILE_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.inl --- a/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.inl Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.inl Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Implementation of client API of mass storage file server // // - -/** - @file - @internalTechnology - Implementation of client API of mass storage file server - */ - #ifndef USBMSCFILE_INL #define USBMSCFILE_INL diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileshared.h --- a/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileshared.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileshared.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,16 +10,10 @@ // // Contributors: // -// Description: +// Description: Shared client/server definitions // // -/** - @file - @internalTechnology - Shared client/server definitions - */ - #ifndef USBMSCFILESHARED_H #define USBMSCFILESHARED_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileuids.hrh --- a/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileuids.hrh Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfileuids.hrh Mon Jan 18 21:13:23 2010 +0200 @@ -14,11 +14,6 @@ // // -/** - @file - @internalTechnology - */ - #ifndef USBMSCFILEUIDS_HRH #define USBMSCFILEUIDS_HRH diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/bulkonlytransport.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/bulkonlytransport.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/bulkonlytransport.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Class declaration for CBulkOnlyTransport. // // - -/** - @file - @internalTechnology - Class declaration for CBulkOnlyTransport. -*/ - #ifndef BULKONLYTRANSPORT_H #define BULKONLYTRANSPORT_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/filesystemimage.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/filesystemimage.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/filesystemimage.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: CFileSystemImage declaration // // -/** - @file - @internalTechnology - - CFileSystemImage declaration -*/ - #ifndef FILESYSTEMIMAGE_H #define FILESYSTEMIMAGE_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilecontroller.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilecontroller.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilecontroller.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Class declaration for CMscFileController. // // - -/** - @file - @internalTechnology - Class declaration for CMscFileController. -*/ - #ifndef MSCFILECONTROLLER_H #define MSCFILECONTROLLER_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: Implements a Symbian OS server that exposes the RUsbMassStorage API // // -/** - @file - @internalTechnology - - Implements a Symbian OS server that exposes the RUsbMassStorage API - */ - #ifndef MSCFILESERVER_H #define MSCFILESERVER_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.inl --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.inl Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserver.inl Mon Jan 18 21:13:23 2010 +0200 @@ -10,18 +10,10 @@ // // Contributors: // -// Description: +// Description: Implements a Symbian OS server that exposes the RUsbMassStorge API // // - -/* - @file - @internalTechnology - - Implements a Symbian OS server that exposes the RUsbMassStorge API - */ - #ifndef MSCFILESERVER_INL #define MSCFILESERVER_INL diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserversecuritypolicy.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserversecuritypolicy.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfileserversecuritypolicy.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,17 +10,10 @@ // // Contributors: // -// Description: +// Description: USB mass storage Server Security Policy definitions for Platform security. // // -/** - * @file - * @internalComponent - * - * USB mass storage Server Security Policy definitions for Platform security. - */ - #ifndef MSCFILESERVERSECURITYPOLICY_H #define MSCFILESERVERSECURITYPOLICY_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilesession.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilesession.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/mscfilesession.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,18 +10,10 @@ // // Contributors: // -// Description: +// Description: Implements a Session of a Symbian OS server for the RUsbMassStorage API // // - -/** - @file - @internalTechnology - - Implements a Session of a Symbian OS server for the RUsbMassStorage API - */ - #ifndef MSCFILESESSION_H #define MSCFILESESSION_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/protocol.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/protocol.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/protocol.h Mon Jan 18 21:13:23 2010 +0200 @@ -14,13 +14,6 @@ // // - - -/** -@file -@internalTechnology -*/ - #ifndef PROTOCOL_H #define PROTOCOL_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/scsiprot.h --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/scsiprot.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/inc/scsiprot.h Mon Jan 18 21:13:23 2010 +0200 @@ -10,18 +10,10 @@ // // Contributors: // -// Description: +// Description: SCSI Protocol layer for USB Mass Storage // // - -/** -@file -@internalTechnology - -SCSI Protocol layer for USB Mass Storage -*/ - #ifndef SCSIPROT_H #define SCSIPROT_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/bulkonlytransport.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/bulkonlytransport.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/bulkonlytransport.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -13,9 +13,7 @@ // Description: // // -/** - @file - */ + #include "bulkonlytransport.h" #include "mscfileserver.h" #include "usbmscfileshared.h" diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/filesystemimage.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/filesystemimage.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/filesystemimage.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,16 +10,11 @@ // // Contributors: // -// Description: +// Description: CFileSystemImage implementation // // -/** - @file - CFileSystemImage implementation - */ - -#include "FileSystemImage.h" +#include "filesystemimage.h" #include "debug.h" const TInt KImageFileMode = EFileShareReadersOnly | EFileRead; diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilecontroller.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilecontroller.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilecontroller.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,15 +10,10 @@ // // Contributors: // -// Description: +// Description: CMscFileController implementation. // // -/** - @file - CMscFileController implementation. -*/ - #include "mscfilecontroller.h" #include "scsiprot.h" #include "bulkonlytransport.h" diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfileserver.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfileserver.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfileserver.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,16 +10,10 @@ // // Contributors: // -// Description: +// Description: Implements a Symbian OS server that exposes the RUsbMassStorage API // // - -/** - @file - Implements a Symbian OS server that exposes the RUsbMassStorage API - */ - #include #include "usbmscfileshared.h" #include "mscfileserver.h" diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilesession.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilesession.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/mscfilesession.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,16 +10,10 @@ // // Contributors: // -// Description: +// Description: Implements a Session of a Symbian OS server for the RUsbMassStorage API // // - -/** - @file - Implements a Session of a Symbian OS server for the RUsbMassStorage API - */ - #include #include #include "mscfilesession.h" diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/scsiprot.cpp --- a/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/scsiprot.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbclasses/usbphoneasmodem/classimplementation/mscfileserver/src/scsiprot.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -10,15 +10,10 @@ // // Contributors: // -// Description: +// Description: SCSI protocol // // -/** - @file - SCSI protocol - */ - #include "scsiprot.h" #include "debug.h" #include "mscfileserver.h" diff -r 705ec7b86991 -r 468cfcb53fd1 usbclasses/usbphoneasmodem/document/S60_USB_Phone_As_Modem.mdzip Binary file usbclasses/usbphoneasmodem/document/S60_USB_Phone_As_Modem.mdzip has changed diff -r 705ec7b86991 -r 468cfcb53fd1 usbengines/usblocodplugin/tsrc/USBLocodPluginTest/group/USBLocodPluginTest.mmp --- a/usbengines/usblocodplugin/tsrc/USBLocodPluginTest/group/USBLocodPluginTest.mmp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbengines/usblocodplugin/tsrc/USBLocodPluginTest/group/USBLocodPluginTest.mmp Mon Jan 18 21:13:23 2010 +0200 @@ -1,4 +1,3 @@ -/*TYPE TESTCLASS*/ /* * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. diff -r 705ec7b86991 -r 468cfcb53fd1 usbengines/usbotgwatcher/group/bld.inf --- a/usbengines/usbotgwatcher/group/bld.inf Thu Jan 07 13:25:34 2010 +0200 +++ b/usbengines/usbotgwatcher/group/bld.inf Mon Jan 18 21:13:23 2010 +0200 @@ -11,7 +11,7 @@ * * Contributors: * -* Description: Build information file for project ?myapp +* Description: Build information file for project usbotgwatcher * */ diff -r 705ec7b86991 -r 468cfcb53fd1 usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest.mmp --- a/usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest.mmp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest.mmp Mon Jan 18 21:13:23 2010 +0200 @@ -1,4 +1,3 @@ -/*TYPE TESTCLASS*/ /* * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. diff -r 705ec7b86991 -r 468cfcb53fd1 usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest_exe.mmp --- a/usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest_exe.mmp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbengines/usbremotepersonality/tsrc/USBRemotePersonalityTest/group/USBRemotePersonalityTest_exe.mmp Mon Jan 18 21:13:23 2010 +0200 @@ -1,4 +1,3 @@ -/*TYPE TESTCLASS*/ /* * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. diff -r 705ec7b86991 -r 468cfcb53fd1 usbengines/usbwatcher/rom/mtp_symbian_temp.iby --- a/usbengines/usbwatcher/rom/mtp_symbian_temp.iby Thu Jan 07 13:25:34 2010 +0200 +++ b/usbengines/usbwatcher/rom/mtp_symbian_temp.iby Mon Jan 18 21:13:23 2010 +0200 @@ -208,4 +208,11 @@ #endif // SYMBIAN_EXCLUDE_MTP #endif// MTP_BT_IBY +#ifndef MTP_CONTROLLER_IBY +#define MTP_CONTROLLER_IBY +#if !defined (SYMBIAN_EXCLUDE_MTP) +//MTP Controller LOCOD service plugin +ECOM_PLUGIN(mtpcontroller.dll, mtpcontroller.rsc) +#endif// SYMBIAN_EXCLUDE_MTP +#endif// MTP_CONTROLLER_IBY #endif // MTPSYMBIANTEMP_IBY__ diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/imageprintui/loc/imageprintui.loc --- a/usbuis/imageprintui/loc/imageprintui.loc Thu Jan 07 13:25:34 2010 +0200 +++ b/usbuis/imageprintui/loc/imageprintui.loc Mon Jan 18 21:13:23 2010 +0200 @@ -12,7 +12,6 @@ * Contributors: * * Description: Localization strings for project Image Print UI -* Version : %version: 13 % * */ diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/imageprintuiprovider/inc/caiwprintingprovider.h --- a/usbuis/imageprintuiprovider/inc/caiwprintingprovider.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbuis/imageprintuiprovider/inc/caiwprintingprovider.h Mon Jan 18 21:13:23 2010 +0200 @@ -24,7 +24,7 @@ #include #include -#include "CAiwImagePrintIf.h" +#include "caiwimageprintif.h" /** diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/BWINS/rndisautherizationnotifieru.def --- a/usbuis/rndisui/BWINS/rndisautherizationnotifieru.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - ?ImplementationGroupProxy@@YAPBUTImplementationProxy@@AAH@Z @ 1 NONAME ; struct TImplementationProxy const * ImplementationGroupProxy(int &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/BWINS/rndisrefusalnotifieru.def --- a/usbuis/rndisui/BWINS/rndisrefusalnotifieru.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - ?ImplementationGroupProxy@@YAPBUTImplementationProxy@@AAH@Z @ 1 NONAME ; struct TImplementationProxy const * ImplementationGroupProxy(int &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/data/nokiarndis.inf --- a/usbuis/rndisui/data/nokiarndis.inf Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,134 +0,0 @@ -; Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -; All rights reserved. -; This component and the accompanying materials are made available -; under the terms of "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: Nokia USB Remote NDIS Device - - -[Version] -Signature = "$Windows NT$" -Class = Net -ClassGUID = {4d36e972-e325-11ce-bfc1-08002be10318} -Provider = %Symbian% -DriverVer = 05/02/2007,0.0.0.1 -;CatalogFile = Symbian.cat - -[Manufacturer] -%Symbian% = SymbianDevices,NT.5.1 - -[SymbianDevices] -%SymbianDevice% = RNDIS, USB\VID_0421&PID_03A3 - -[SymbianDevices.NT.5.1] -%SymbianDevice% = RNDIS.NT.5.1, USB\VID_0421&PID_03A3 - -[ControlFlags] -ExcludeFromSelect=* - -; Windows 2000 specific sections --------------------------------- - -[RNDIS.NT] -Characteristics = 0x84 ; NCF_PHYSICAL + NCF_HAS_UI -BusType = 15 -DriverVer = 05/02/2007,0.0.0.1 -AddReg = RNDIS_AddReg_NT, RNDIS_AddReg_WIN2K -CopyFiles = RNDIS_CopyFiles_NT - -; DO NOT MODIFY THE SERVICE NAME -[RNDIS.NT.Services] -AddService = USB_RNDISY, 2, RNDIS_ServiceInst_NT, RNDIS_EventLog - -[RNDIS_CopyFiles_NT] -; no rename of files on Windows 2000, use the 'y' names as is -usb8023y.sys, , , 0 -rndismpy.sys, , , 0 - -[RNDIS_ServiceInst_NT] -DisplayName = %ServiceDisplayName% -ServiceType = 1 -StartType = 3 -ErrorControl = 1 -ServiceBinary = %12%\usb8023y.sys -LoadOrderGroup = NDIS -AddReg = RNDIS_WMI_AddReg_NT - -[RNDIS_WMI_AddReg_NT] -HKR, , MofImagePath, 0x00020000, "System32\drivers\rndismpy.sys" - -; Windows XP specific sections ----------------------------------- - -[RNDIS.NT.5.1] -Characteristics = 0x84 ; NCF_PHYSICAL + NCF_HAS_UI -BusType = 15 -DriverVer = 05/02/2007,0.0.0.1 -AddReg = RNDIS_AddReg_XP -include = netrndis.inf -needs = Usb_Rndis.ndi - -; no copyfiles - the files are already in place - -[RNDIS.NT.5.1.Services] -include = netrndis.inf -needs = Usb_Rndis.ndi.Services - -; Windows 2000 sections - -; DO NOT MODIFY ServiceName -[RNDIS_AddReg_NT] -HKR, Ndi, Service, 0, "USB_RNDISY" -HKR, Ndi\Interfaces, UpperRange, 0, "ndis5" -HKR, Ndi\Interfaces, LowerRange, 0, "ethernet" - -[RNDIS_AddReg_WIN2K] -HKR, , ReclaimRecv, 0x00010001, 1 -HKR, NDI\params\NetworkAddress, ParamDesc, 0, %NetworkAddress% -HKR, NDI\params\NetworkAddress, type, 0, "edit" -HKR, NDI\params\NetworkAddress, LimitText, 0, "12" -HKR, NDI\params\NetworkAddress, UpperCase, 0, "1" -HKR, NDI\params\NetworkAddress, default, 0, " " -HKR, NDI\params\NetworkAddress, optional, 0, "1" - -[RNDIS_EventLog] -AddReg = RNDIS_EventLog_AddReg - -[RNDIS_EventLog_AddReg] -HKR, , EventMessageFile, 0x00020000, "%%SystemRoot%%\System32\netevent.dll" -HKR, , TypesSupported, 0x00010001, 7 - -; An optional Property to demonstrate adding advanced properties on Windows XP -[RNDIS_AddReg_XP] -HKR, NDI\params\XPProperty, ParamDesc, 0, %Sample_Property% -HKR, NDI\params\XPProperty, type, 0, "edit" -HKR, NDI\params\XPProperty, LimitText, 0, "12" -HKR, NDI\params\XPProperty, UpperCase, 0, "1" -HKR, NDI\params\XPProperty, default, 0, " " -HKR, NDI\params\XPProperty, optional, 0, "1" - - -[SourceDisksNames] -1=%SourceDisk%,,1 - -[SourceDisksFiles] -usb8023y.sys=1 -rndismpy.sys=1 - -[DestinationDirs] -RNDIS_CopyFiles_NT = 12 - -; DO NOT CHANGE ServiceDisplayName -[Strings] -ServiceDisplayName = "USB Remote NDIS Y Network Device Driver" -Sample_Property = "Sample XP property" -NetworkAddress = "Network Address" -Symbian = "Symbian Software" -SymbianDevice = "Symbian USB Remote NDIS Network Device" -SourceDisk = "Symbian USB Network Driver Install Disk" - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/data/rndisauthorizationnotifier.rss --- a/usbuis/rndisui/data/rndisauthorizationnotifier.rss Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,43 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: RNDIS uplink authorization notifier resource file -* -*/ - -#include -#include -#include "rndisauthorizationnotifier.hrh" - -RESOURCE REGISTRY_INFO r_registry - { - dll_uid = KUidUplinkAuthNotifierValue; - interfaces = - { - INTERFACE_INFO - { - interface_uid = KUikonUidPluginInterfaceNotifiers; - implementations = - { - IMPLEMENTATION_INFO - { - implementation_uid = KUidUplinkAuthNotifierImp; - version_no = 1; - display_name = "Uplink Authorization Notifier Plugin"; - default_data = "UplinkAuthNotifier"; - opaque_data = "0"; - } - }; - } - }; - } diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/data/rndisrefusalnotifier.rss --- a/usbuis/rndisui/data/rndisrefusalnotifier.rss Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,43 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: RNDIS refusal notifier resource file -* -*/ - -#include -#include -#include "rndisrefusalnotifier.hrh" - -RESOURCE REGISTRY_INFO theInfo - { - dll_uid = KUidNetworkConnectionRefusalNotifierValue; - interfaces = - { - INTERFACE_INFO - { - interface_uid = KUikonUidPluginInterfaceNotifiers; - implementations = - { - IMPLEMENTATION_INFO - { - implementation_uid = KUidNetworkConnectionRefusalNotifierImp; - version_no = 1; - display_name = "RNDIS Network Connection Refusal Notifier Plugin"; - default_data = "RndisNetworkConnectionRefusalNotifier"; - opaque_data = ""; - } - }; - } - }; - } diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/eabi/rndisautherizationnotifieru.def --- a/usbuis/rndisui/eabi/rndisautherizationnotifieru.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - _Z24ImplementationGroupProxyRi @ 1 NONAME - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/eabi/rndisrefusalnotifieru.def --- a/usbuis/rndisui/eabi/rndisrefusalnotifieru.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - _Z24ImplementationGroupProxyRi @ 1 NONAME - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/group/bld.inf --- a/usbuis/rndisui/group/bld.inf Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -/* -* Copyright (c) 2005, 2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: This file provides building information for RNDIS for debugging. -* -*/ - -#include - -PRJ_PLATFORMS -DEFAULT - -PRJ_EXPORTS -../rom/rndisauthorizationnotifier.iby CORE_MW_LAYER_IBY_EXPORT_PATH(rndisauthorizationnotifier.iby) -../rom/rndisrefusalnotifier.iby CORE_MW_LAYER_IBY_EXPORT_PATH(rndisrefusalnotifier.iby) - -PRJ_MMPFILES -./rndisauthorizationnotifier.mmp -./rndisrefusalnotifier.mmp - -PRJ_TESTMMPFILES - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/group/rndisauthorizationnotifier.mmp --- a/usbuis/rndisui/group/rndisauthorizationnotifier.mmp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,45 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: definition file for RNDIS uplink authorization notifier -* -*/ - -#include "../inc/rndisauthorizationnotifier.hrh" - -TARGET rndisauthorizationnotifier.dll -TARGETTYPE PLUGIN -UID 0x10009D8D KUidUplinkAuthNotifierValue -CAPABILITY CAP_ECOM_PLUGIN -VENDORID VID_DEFAULT -DEFFILE rndisautherizationnotifier.def - -USERINCLUDE ../inc -MW_LAYER_SYSTEMINCLUDE - -SOURCEPATH ../src - -SOURCE rndisauthorizationnotifier.cpp - -//Notifier resource file -START RESOURCE ../data/rndisauthorizationnotifier.rss - TARGET rndisauthorizationnotifier.rsc -END - -LIBRARY eiksrv.lib -LIBRARY ecom.lib -LIBRARY euser.lib - -NOEXPORTLIBRARY - -SMPSAFE diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/group/rndisrefusalnotifier.mmp --- a/usbuis/rndisui/group/rndisrefusalnotifier.mmp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,46 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: definition file for RNDIS refusal notifier -* -*/ - -#include "../inc/rndisrefusalnotifier.hrh" - -TARGET rndisrefusalnotifier.dll -TARGETTYPE PLUGIN -UID 0x10009D8D KUidNetworkConnectionRefusalNotifierValue -CAPABILITY CAP_ECOM_PLUGIN -VENDORID VID_DEFAULT - -DEFFILE rndisrefusalnotifier.def - -USERINCLUDE ../inc - -MW_LAYER_SYSTEMINCLUDE - -SOURCEPATH ../src -SOURCE rndisrefusalnotifier.cpp - -//Refusal notifier resource file -START RESOURCE ../data/rndisrefusalnotifier.rss - TARGET rndisrefusalnotifier.rsc -END - -LIBRARY euser.lib -LIBRARY ecom.lib -LIBRARY eiksrv.lib - -NOEXPORTLIBRARY - -SMPSAFE diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/inc/rndisauthorizationnotifier.h --- a/usbuis/rndisui/inc/rndisauthorizationnotifier.h Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,58 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: Header file for RNDIS uplink authorization notifier -* -*/ - -/** -@file -@internalComponent -*/ - -#ifndef RNDISAUTHORIZATIONNOTIFIER_H -#define RNDISAUTHORIZATIONNOTIFIER_H - -#include // CBase -#include // TBuf -#include // For MEikSrvNotifierBase2 - -NONSHARABLE_CLASS(CRndisAuthorizationNotifier) - : public CBase - , public MEikSrvNotifierBase2 - { -public: - // Create CRndisAuthorizationNotifier. - static CRndisAuthorizationNotifier* NewLC(); - // Destructor - virtual ~CRndisAuthorizationNotifier(); - -public: - // virtual functions from MEikSrvNotifierBase2 - virtual void Release(); - virtual TNotifierInfo RegisterL(); - virtual TNotifierInfo Info() const; - virtual void StartL(const TDesC8& aBuffer, TInt aReplySlot, const RMessagePtr2& aMessage); - virtual TPtrC8 StartL(const TDesC8& aBuffer); - virtual void Cancel(); - virtual TPtrC8 UpdateL(const TDesC8& aBuffer); - -private: - CRndisAuthorizationNotifier(); - void ConstructL(); - -private: - TNotifierInfo iInfo; - }; - -#endif //RNDISAUTHORIZATIONNOTIFIER_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/inc/rndisauthorizationnotifier.hrh --- a/usbuis/rndisui/inc/rndisauthorizationnotifier.hrh Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: -* -*/ - -/** -@file -@internalComponent -*/ - -#ifndef RNDISAUTHORIZATIONNOTIFIER_HRH -#define RNDISAUTHORIZATIONNOTIFIER_HRH - -// This is the dll plugin id. -#define KUidUplinkAuthNotifierValue 0xA000EA56 - -// KUidUplinkAuthNotifierImp must be equal to KUidRndisUplinkAuthorizationNotifier -// which defined in rndisuiinterfaces.h -#define KUidUplinkAuthNotifierImp 0x10286A44 - -#endif //RNDISAUTHORIZATIONNOTIFIER_HRH diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/inc/rndisrefusalnotifier.h --- a/usbuis/rndisui/inc/rndisrefusalnotifier.h Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,60 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: Header file for RNDIS refusal notifier -* -*/ - -/** -@file -@internalComponent -*/ - -#ifndef RNDISREFUSALNOTIFIER_H -#define RNDISREFUSALNOTIFIER_H - -#include // CBase -#include // TBuf -#include // For MEikSrvNotifierBase2 - -NONSHARABLE_CLASS(CRndisNetworkConnectionRefusalNotifier) - : public MEikSrvNotifierBase2 -/** -RNDIS network connection refusal notifier -*/ - { -public: - //Create CRndisNetworkConnectionRefusalNotifier. - static CRndisNetworkConnectionRefusalNotifier* NewLC(); - //Destructor - ~CRndisNetworkConnectionRefusalNotifier(); - -public: - // virtual functions from MEikSrvNotifierBase2 - virtual void Release(); - virtual TNotifierInfo RegisterL(); - virtual TNotifierInfo Info() const; - virtual TPtrC8 StartL(const TDesC8& aBuffer); - virtual void StartL(const TDesC8& aBuffer, TInt aReplySlot, const RMessagePtr2& aMessage); - virtual void Cancel(); - virtual TPtrC8 UpdateL(const TDesC8& aBuffer); - -private: - CRndisNetworkConnectionRefusalNotifier(); - void ConstructL(); - -private: - TNotifierInfo iInfo; - }; - -#endif //RNDISREFUSALNOTIFIER_H diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/inc/rndisrefusalnotifier.hrh --- a/usbuis/rndisui/inc/rndisrefusalnotifier.hrh Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: -* -*/ - -/** -@file -@internalComponent -*/ - -#ifndef RNDISREFUSALNOTIFIER_HRH -#define RNDISREFUSALNOTIFIER_HRH - -// This is the dll plugin id. -#define KUidNetworkConnectionRefusalNotifierValue 0xA000EA55 - -// KUidNetworkConnectionRefusalNotifierImp must be equal to -// KUidRndisNetworkConnectionRefusalNotifier which defined in rndisuiinterfaces.h -#define KUidNetworkConnectionRefusalNotifierImp 0x10286A45 - -#endif // RNDISREFUSALNOTIFIER_HRH diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/rom/rndisauthorizationnotifier.iby --- a/usbuis/rndisui/rom/rndisauthorizationnotifier.iby Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,25 +0,0 @@ -/* -* 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 "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: RNDIS uplink authorization notifier iby file -* -*/ -#ifndef __RNDISAUTHORIZATIONNOTIFIER_IBY -#define __RNDISAUTHORIZATIONNOTIFIER_IBY - - -REM USB RNDIS UI notifiers ecom plug-in - -ECOM_PLUGIN(rndisauthorizationnotifier.dll, rndisauthorizationnotifier.rsc) - -#endif //__RNDISAUTHORIZATIONNOTIFIER_IBY diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/rom/rndisrefusalnotifier.iby --- a/usbuis/rndisui/rom/rndisrefusalnotifier.iby Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,22 +0,0 @@ -/* -* 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 "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: RNDIS refusal notifier iby file -* -*/ -#ifndef __RNDISREFUSALNOTIFIER_IBY -#define __RNDISREFUSALNOTIFIER_IBY - -ECOM_PLUGIN(rndisrefusalnotifier.dll, rndisrefusalnotifier.rsc) - -#endif // __RNDISREFUSALNOTIFIER_IBY diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/src/rndisauthorizationnotifier.cpp --- a/usbuis/rndisui/src/rndisauthorizationnotifier.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,116 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: source file for RNDIS uplink authorization notifier -* -*/ - -/** -@file -@internalComponent -*/ - -#include -#include -#include -#include "rndisauthorizationnotifier.hrh" -#include "rndisauthorizationnotifier.h" - -using namespace UsbRndis; - -CRndisAuthorizationNotifier* CRndisAuthorizationNotifier::NewLC() - { - CRndisAuthorizationNotifier* self = new (ELeave)CRndisAuthorizationNotifier(); - CleanupStack::PushL(self); - self->ConstructL(); - return self; - } - -CRndisAuthorizationNotifier::CRndisAuthorizationNotifier() - { - } - -void CRndisAuthorizationNotifier::ConstructL() - { - } - -CRndisAuthorizationNotifier::~CRndisAuthorizationNotifier() - { - } - -void CRndisAuthorizationNotifier::Release() - { - delete this; - } - -CRndisAuthorizationNotifier::TNotifierInfo CRndisAuthorizationNotifier::RegisterL() - { - //Return TNotifierInfo, describes the parameters of the notifier - iInfo.iUid = TUid::Uid(KUidUplinkAuthNotifierImp); - iInfo.iChannel = TUid::Uid(KUidUplinkAuthNotifierImp); - iInfo.iPriority = ENotifierPriorityHigh; - return iInfo; - } - -CRndisAuthorizationNotifier::TNotifierInfo CRndisAuthorizationNotifier::Info() const - { - //Return TNotifierInfo, describes the parameters of the notifier - return iInfo; - } - -TPtrC8 CRndisAuthorizationNotifier::StartL(const TDesC8& /*aBuffer*/) - { - // Do not support synchronous start, just return. - return KNullDesC8(); - } - -void CRndisAuthorizationNotifier::StartL(const TDesC8& /*aBuffer*/, TInt aReplySlot, const RMessagePtr2& aMessage) - { - // Just to set as DisAllow defaultly .. - TRndisUplinkAuthorizationResultPckg selection(ERndisDisallowUplinkAccess); - aMessage.Write(aReplySlot, selection); - aMessage.Complete(KErrNone); - } - -void CRndisAuthorizationNotifier::Cancel() - { - } - -TPtrC8 CRndisAuthorizationNotifier::UpdateL(const TDesC8&) - { - // Do not support update, just return. - return KNullDesC8(); - } - -CArrayPtr* NotifierArrayL() - { - CArrayPtrFlat* notifiers = new(ELeave) CArrayPtrFlat(1); - CleanupStack::PushL(notifiers); - CRndisAuthorizationNotifier* notifier = CRndisAuthorizationNotifier::NewLC(); - notifiers->AppendL(notifier); - CleanupStack::Pop(2, notifiers); - return notifiers; - } - -// ECom plugin entry point -const TImplementationProxy ImplementationTable[] = - { - IMPLEMENTATION_PROXY_ENTRY(KUidUplinkAuthNotifierImp, NotifierArrayL) - }; - -// ECom plugin entry point -EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) - { - aTableCount = sizeof(ImplementationTable) / sizeof(TImplementationProxy); - return ImplementationTable; - } diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/rndisui/src/rndisrefusalnotifier.cpp --- a/usbuis/rndisui/src/rndisrefusalnotifier.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,109 +0,0 @@ -/* -* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: Source file for RNDIS refusal notifier -* -*/ - -/** -@file -@internalComponent -*/ - -#include -#include -#include "rndisrefusalnotifier.hrh" -#include "rndisrefusalnotifier.h" - -using namespace UsbRndis; - -//Number of notifier needed. -const TInt KNotfierCount = 1; - -CRndisNetworkConnectionRefusalNotifier* CRndisNetworkConnectionRefusalNotifier::NewLC() - { - CRndisNetworkConnectionRefusalNotifier* self = new (ELeave) CRndisNetworkConnectionRefusalNotifier; - CleanupStack::PushL(self); - self->ConstructL(); - return self; - } - -CRndisNetworkConnectionRefusalNotifier::CRndisNetworkConnectionRefusalNotifier() - { - } - -CRndisNetworkConnectionRefusalNotifier::~CRndisNetworkConnectionRefusalNotifier() - { - } - -void CRndisNetworkConnectionRefusalNotifier::ConstructL() - { - } - -void CRndisNetworkConnectionRefusalNotifier::Release() - { - delete this; - } - -MEikSrvNotifierBase2::TNotifierInfo CRndisNetworkConnectionRefusalNotifier::RegisterL() - { - iInfo.iUid=TUid::Uid(KUidNetworkConnectionRefusalNotifierImp); - iInfo.iChannel = TUid::Uid(KUidNetworkConnectionRefusalNotifierImp); - iInfo.iPriority=ENotifierPriorityHigh; - return iInfo; - } - -MEikSrvNotifierBase2::TNotifierInfo CRndisNetworkConnectionRefusalNotifier::Info() const - { - return iInfo; - } - -TPtrC8 CRndisNetworkConnectionRefusalNotifier::StartL(const TDesC8& aBuffer) - { - return aBuffer; - } - -void CRndisNetworkConnectionRefusalNotifier::StartL(const TDesC8& /*aBuffer*/, TInt /*aReplySlot*/, const RMessagePtr2& aMessage) - { - aMessage.Complete(KErrNone); - } - -void CRndisNetworkConnectionRefusalNotifier::Cancel() - { - } - -TPtrC8 CRndisNetworkConnectionRefusalNotifier::UpdateL(const TDesC8& aBuffer) - { - return aBuffer; - } - -CArrayPtr* NotifierArrayL() - { - CArrayPtr* array = new(ELeave) CArrayPtrFlat(KNotfierCount); - CleanupStack::PushL(array); - array->AppendL(CRndisNetworkConnectionRefusalNotifier::NewLC()); - CleanupStack::Pop(2, array); - return array; - } - -// ECom plugin entry point -const TImplementationProxy ImplementationTable[] = - { - IMPLEMENTATION_PROXY_ENTRY(KUidNetworkConnectionRefusalNotifierImp, NotifierArrayL) - }; - -EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) - { - aTableCount = sizeof(ImplementationTable)/sizeof(TImplementationProxy); - return ImplementationTable; - } diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/USBClassChangeUIPlugin/src/USBClassChangeUIPluginContainer.cpp --- a/usbuis/usbui/USBClassChangeUIPlugin/src/USBClassChangeUIPluginContainer.cpp Thu Jan 07 13:25:34 2010 +0200 +++ b/usbuis/usbui/USBClassChangeUIPlugin/src/USBClassChangeUIPluginContainer.cpp Mon Jan 18 21:13:23 2010 +0200 @@ -269,14 +269,17 @@ void CUSBClassChangeUIPluginContainer::ShowPopUpsL(TInt aIndex) { FLOG(_L("[CUSBClassChangeUIPlugin]\t CUSBClassChangeUIPluginContainer::ShowPopUpsL ")); - iPopupController->SetTimePopupInView( KMaxVisibleTime); - TPtrC chosen = iPopUpItems->MdcaPoint(aIndex); - iPopupController->SetTextL( chosen ); - iPopupController->SetPositionByHighlight( TRect( + if ( aIndex >= 0 && aIndex < iPopUpItems->Count() ) + { + iPopupController->SetTimePopupInView( KMaxVisibleTime); + TPtrC chosen = iPopUpItems->MdcaPoint(aIndex); + iPopupController->SetTextL( chosen ); + iPopupController->SetPositionByHighlight( TRect( iUSBMainListBox->View()->ItemPos( aIndex + 1 ), iUSBMainListBox->View()->ItemSize() ) ); - iPopupController->SetTimeDelayBeforeShow( KMsToWaitBeforePopup ); - iPopupController->ShowInfoPopupNote(); + iPopupController->SetTimeDelayBeforeShow( KMsToWaitBeforePopup ); + iPopupController->ShowInfoPopupNote(); + } FLOG(_L("[CUSBClassChangeUIPlugin]\t CUSBClassChangeUIPluginContainer::ShowPopUpsL complete")); } diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/Bmarm/USBUiApiTestU.DEF --- a/usbuis/usbui/tsrc/USBUiApiTest/Bmarm/USBUiApiTestU.DEF Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - LibEntryL__FR13CTestModuleIf @ 1 NONAME R3UNUSED ; LibEntryL(CTestModuleIf &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/Bwins/USBUiApiTestU.DEF --- a/usbuis/usbui/tsrc/USBUiApiTest/Bwins/USBUiApiTestU.DEF Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - ?LibEntryL@@YAPAVCScriptBase@@AAVCTestModuleIf@@@Z @ 1 NONAME ; class CScriptBase * __cdecl LibEntryL(class CTestModuleIf &) - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/EABI/USBUiApiTestU.def --- a/usbuis/usbui/tsrc/USBUiApiTest/EABI/USBUiApiTestU.def Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -EXPORTS - _Z9LibEntryLR13CTestModuleIf @ 1 NONAME - diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/conf/ui_USBUiApiTest.cfg --- a/usbuis/usbui/tsrc/USBUiApiTest/conf/ui_USBUiApiTest.cfg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,238 +0,0 @@ -// USB UI tests - total 14 tc -///////////////////// -//Ovi->MS -[Test] -title Change USB Connection Ovi Suite to MS Manual/KeyDown -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MS -delete tester -[Endtest] - -[Test] -title Change USB Connection Ovi Suite to MS Manual/KeyUp -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyUpArrow -pause 500 -presskey global EKeyUpArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MS -delete tester -[Endtest] -///////////////////////// -//Ovi->MTP -[Test] -title Change USB Connection Ovi Suite to MTP Manual/KeyUp -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyUpArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MTP -delete tester -[Endtest] - -[Test] -title Change USB Connection Ovi Suite to MTP Manual/KeyDown -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -pause 500 -presskey global EKeyDownArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MTP -delete tester -[Endtest] -///////////////////////// -//MS->Ovi -[Test] -title Change USB Connection MS to Ovi Suite Manual -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MS -tester TurnLightsOn -pause 4000 -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF PCSUITE -delete tester -[Endtest] -///////////////////////// -//MS->MTP -[Test] -title Change USB Connection MS to MTP Manual -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MS -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -pause 500 -presskey global EKeyDownArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MTP -delete tester -[Endtest] -///////////////////////// -//MTP->Ovi -[Test] -title Change USB Connection MTP to Ovi Suite Manual/KeyDown -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MTP -tester TurnLightsOn -pause 4000 -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF PCSUITE -delete tester -[Endtest] -///////////////////////// -//MTP->MS -[Test] -title Change USB Connection MTP to MS Manual/KeyDown -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MTP -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MS -delete tester -[Endtest] -///////////////////////// -//Change In Options Menu -//MS->MTP -[Test] -title Change USB Connection MS to MTP Change In Options Menu -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MS -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -pause 500 -presskey global EKeyDownArrow -presskey global EKeyDevice0 -pause 2000 -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MTP -delete tester -[Endtest] -///////////////////////// -//MTP->Ovi -[Test] -title Change USB Connection MTP to Ovi Suite Change In Options Menu -create USBUiApiTest tester -tester LaunchUsbUiApp OFF MTP -tester TurnLightsOn -pause 4000 -presskey global EKeyDevice0 -pause 2000 -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF PCSUITE -delete tester -[Endtest] -///////////////////////// -//Ovi->MS -[Test] -title Change USB Connection Ovi Suite to MS Change In Options Menu -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDownArrow -presskey global EKeyDevice0 -pause 2000 -presskey global EKeyEnter -pause 1000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest USB_CONN_MODE OFF MS -delete tester -[Endtest] -///////////////////////// -//Exit -[Test] -title USB Application Cancelled/Device Key 1 Exit -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest CANCELLED -delete tester -[Endtest] -///////////////////////// -//Cancel -[Test] -title USB Application Cancelled/Options Menu Exit -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDevice0 -pause 500 -presskey global EKeyDownArrow -presskey global EKeyDownArrow -presskey global EKeyEnter -pause 2000 -tester FinishTest CANCELLED -delete tester -[Endtest] -///////////////////////// -//Help -[Test] -title USB Application Cancelled/Help Option Entered/Options Menu Exit -create USBUiApiTest tester -tester LaunchUsbUiApp OFF PCSUITE -tester TurnLightsOn -pause 4000 -presskey global EKeyDevice0 -pause 500 -presskey global EKeyDownArrow -pause 500 -presskey global EKeyEnter -pause 5000 -presskey global EKeyDevice1 -pause 2000 -presskey global EKeyDevice1 -pause 2000 -tester FinishTest CANCELLED -delete tester -[Endtest] diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest.mmp --- a/usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest.mmp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,52 +0,0 @@ -/*TYPE TESTCLASS*//* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - -#if defined(__S60_) - // To get the OSEXT_LAYER_SYSTEMINCLUDE-definition - #include -#endif - -TARGET USBUiApiTest.dll -TARGETTYPE dll -UID 0x1000008D 0x101FB3E3 - -CAPABILITY ALL -TCB - -DEFFILE USBUiApiTest.def - -//#define ATS - -MW_LAYER_SYSTEMINCLUDE - -USERINCLUDE ../inc -USERINCLUDE ../../../inc - -SOURCEPATH ../src -SOURCE USBUiApiTest.cpp -SOURCE USBUiApiTestBlocks.cpp - -LIBRARY euser.lib -LIBRARY stiftestinterface.lib -LIBRARY stiftestengine.lib -LIBRARY centralrepository.lib -LIBRARY apparc.lib -LIBRARY apgrfx.lib - -LANG SC - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest.pkg --- a/usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest.pkg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,64 +0,0 @@ -; -; 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 "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: -; -; -; Installation file for STIF -; - -; Languages -&EN - -; Provide value for uid -#{"STIF"},(0x00000000),1,1,0,TYPE=SA - -; Series60 product id for S60 3.0 -[0x1028315F], 0, 0, 0, {"Series60ProductID"} - -; Localised Vendor name -%{"Nokia"} - -; Unique Vendor name -:"Nokia" - -; Logo -; None - -; Package signature - Optional -; None - -; Start of Package body - -; Condition blocks -; None - -; Options list -; None - -; Install files -"\epoc32\release\armv5\udeb\USBUiApiTest.dll"-"c:\Sys\Bin\USBUiApiTest.dll" - -"..\init\USBUiApiTest.ini"-"e:\testing\init\USBUiApiTest.ini" -"..\conf\ui_USBUiApiTest.cfg"-"e:\testing\conf\ui_USBUiApiTest.cfg" - -; Embedded SIS -; None - -; End of Package body - -; PKG dependencies -; None - -; PKG capabilities -; None diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest_phone.pkg --- a/usbuis/usbui/tsrc/USBUiApiTest/group/USBUiApiTest_phone.pkg Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,63 +0,0 @@ -; -; 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 "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: -; -; -; Installation file for STIF -; - -; Languages -&EN - -; Provide value for uid -#{"STIF"},(0x00000000),1,1,0,TYPE=SA - -; Series60 product id for S60 3.0 -[0x1028315F], 0, 0, 0, {"Series60ProductID"} - -; Localised Vendor name -%{"Nokia"} - -; Unique Vendor name -:"Nokia" - -; Logo -; None - -; Package signature - Optional -; None - -; Start of Package body - -; Condition blocks -; None - -; Options list -; None - -; Install files -"\epoc32\release\armv5\urel\USBUiApiTest.dll"-"c:\Sys\Bin\USBUiApiTest.dll" -"..\init\USBUiApiTest_phone.ini"-"c:\testframework\testframework.ini" -"..\conf\ui_USBUiApiTest.cfg"-"c:\testframework\ui_USBUiApiTest.cfg" - -; Embedded SIS -; None - -; End of Package body - -; PKG dependencies -; None - -; PKG capabilities -; None \ No newline at end of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/bld.inf --- a/usbuis/usbui/tsrc/USBUiApiTest/group/bld.inf Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,30 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - -PRJ_PLATFORMS -DEFAULT - -PRJ_TESTEXPORTS - -PRJ_EXPORTS - -PRJ_TESTMMPFILES -USBUiApiTest.mmp - -PRJ_MMPFILES - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/build_sis.bat --- a/usbuis/usbui/tsrc/USBUiApiTest/group/build_sis.bat Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,19 +0,0 @@ -rem -rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -rem All rights reserved. -rem This component and the accompanying materials are made available -rem under the terms of "Eclipse Public License v1.0" -rem which accompanies this distribution, and is available -rem at the URL "http://www.eclipse.org/legal/epl-v10.html". -rem -rem Initial Contributors: -rem Nokia Corporation - initial contribution. -rem -rem Contributors: -rem -rem Description: -rem - -call abld test build armv5 -call makesis USBUiApiTest.pkg -call signsis USBUiApiTest.sis USBUiApiTest.sisx rd.cer rd-key.pem diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/group/build_sis_phone.bat --- a/usbuis/usbui/tsrc/USBUiApiTest/group/build_sis_phone.bat Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,24 +0,0 @@ -rem -rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). -rem All rights reserved. -rem This component and the accompanying materials are made available -rem under the terms of "Eclipse Public License v1.0" -rem which accompanies this distribution, and is available -rem at the URL "http://www.eclipse.org/legal/epl-v10.html". -rem -rem Initial Contributors: -rem Nokia Corporation - initial contribution. -rem -rem Contributors: -rem -rem Description: -rem - -rd /S /Q \epoc32\BUILD -del USBUiApiTest_phone.sisx -call bldmake bldfiles -call abld reallyclean armv5 -call abld test build armv5 -call makesis USBUiApiTest_phone.pkg -call signsis USBUiApiTest_phone.sis USBUiApiTest_phone.sisx rd.cer rd-key.pem -del USBUiApiTest_phone.sis \ No newline at end of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/inc/USBUiApiTest.h --- a/usbuis/usbui/tsrc/USBUiApiTest/inc/USBUiApiTest.h Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,255 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - -#ifndef USBUIAPITEST_H -#define USBUIAPITEST_H - -// INCLUDES -#include -#include -#include -#include - -#include "coreapplicationuisdomainpskeys.h" -#include -#include -#include -#include -#include -#include - -#include "USBClassChangeUI.h" - -// CONSTANTS -_LIT( KUsbAppFileName, "usbclasschangeui" ); - -// MACROS -//#define ?macro ?macro_def -#define TEST_CLASS_VERSION_MAJOR 0 -#define TEST_CLASS_VERSION_MINOR 0 -#define TEST_CLASS_VERSION_BUILD 0 - -#ifdef STIF_LOG -#undef STIF_LOG -#endif - -#define STIF_LOG( s )\ - {\ - TBuf traceBuf;\ - traceBuf.Append( _L( "[STIF_LOG] " ) );\ - traceBuf.Append( _L( s ) );\ - iLog->Log( _L( s ) );\ - RDebug::Print( traceBuf );\ - } - -#define STIF_LOG1( s, v ) \ - {\ - TBuf traceBuf;\ - traceBuf.Append( _L( "[STIF_LOG] " ) );\ - traceBuf.Append( _L( s ) );\ - iLog->Log( _L( s ), v );\ - RDebug::Print( traceBuf, v );\ - } - -#define STIF_LOG2( s, v1, v2 ) \ - {\ - TBuf traceBuf;\ - traceBuf.Append( _L( "[STIF_LOG] " ) );\ - traceBuf.Append( _L( s ) );\ - iLog->Log( _L( s ), v1, v2 );\ - RDebug::Print( traceBuf, v1, v2 );\ - } - -#define STIF_LOG3( s, v1, v2, v3 ) \ - {\ - TBuf traceBuf;\ - traceBuf.Append( _L( "[STIF_LOG] " ) );\ - traceBuf.Append( _L( s ) );\ - iLog->Log( _L( s ), v1, v2, v3 );\ - RDebug::Print( traceBuf, v1, v2, v3 );\ - } - - -// Logging path -#ifndef ATS -_LIT( KUSBUiApiTestLogPath, "\\logs\\testframework\\usb\\" ); -#else -_LIT( KUSBUiApiTestLogPath, "e:\\testing\\stiflogs\\" ); -#endif -// Log file -_LIT( KUSBUiApiTestLogFile, "USBUiApiTest.txt" ); -_LIT( KUSBUiApiTestLogFileWithTitle, "USBUiApiTest_[%S].txt" ); - -// FUNCTION PROTOTYPES -//?type ?function_name(?arg_list); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; -class CUSBUiApiTest; - -// DATA TYPES -//enum ?declaration -enum TUSBAppTestOption - { - EAppCancelled = 0, - EAskOnConnectionSettingChanged,//1 - EUsbConnectionModeSettingChanged//2 - }; -//typedef ?declaration -//extern ?data_type; - -// CLASS DECLARATION - -/** -* CUSBUiApiTest test class for STIF Test Framework TestScripter. -* ?other_description_lines -* -* @lib ?library -* @since ?Series60_version -*/ -NONSHARABLE_CLASS(CUSBUiApiTest) : public CScriptBase - { - public: // Constructors and destructor - - /** - * Two-phased constructor. - */ - static CUSBUiApiTest* NewL( CTestModuleIf& aTestModuleIf ); - - /** - * Destructor. - */ - virtual ~CUSBUiApiTest(); - - public: // New functions - - /** - * ?member_description. - * @since ?Series60_version - * @param ?arg1 ?description - * @return ?description - */ - //?type ?member_function( ?type ?arg1 ); - - public: // Functions from base classes - - /** - * From CScriptBase Runs a script line. - * @since ?Series60_version - * @param aItem Script line containing method name and parameters - * @return Symbian OS error code - */ - virtual TInt RunMethodL( CStifItemParser& aItem ); - - protected: // New functions - - /** - * ?member_description. - * @since ?Series60_version - * @param ?arg1 ?description - * @return ?description - */ - //?type ?member_function( ?type ?arg1 ); - - protected: // Functions from base classes - - /** - * From ?base_class ?member_description - */ - //?type ?member_function(); - - private: - - /** - * C++ default constructor. - */ - CUSBUiApiTest( CTestModuleIf& aTestModuleIf ); - - /** - * By default Symbian 2nd phase constructor is private. - */ - void ConstructL(); - - // Prohibit copy constructor if not deriving from CBase. - // ?classname( const ?classname& ); - // Prohibit assigment operator if not deriving from CBase. - // ?classname& operator=( const ?classname& ); - - /** - * Frees all resources allocated from test methods. - * @since ?Series60_version - */ - void Delete(); - - /** - * Test methods are listed below. - */ - - virtual TInt LaunchUsbUiApp( CStifItemParser& aItem ); - virtual TInt FinishTest( CStifItemParser& aItem ); - - /** - * Method used to log version of test class - */ - void SendTestClassVersion(); - - //ADD NEW METHOD DEC HERE - //[TestMethods] - Do not remove - TInt GetTestOption( TPtrC aOptionString, TUSBAppTestOption& aOption ); - TInt GetAskOnConnectionOptionFromString( TPtrC aOptionString, TInt& aOption ); - TInt GetUsbPersonalityOptionFromString( TPtrC aOptionString, TInt& aOption ); - TBool IsUsbAppRunning(); - TInt GetUsbSettings( TInt& aUsbPersinalityId, TInt& aAskOnConnectionSetting ); - TInt SetUsbSettings( TInt aUsbPersinalityId, TInt aAskOnConnectionSetting ); - - TInt TurnLightsOn( CStifItemParser& aItem ); - - public: // Data - // ?one_line_short_description_of_data - //?data_declaration; - - protected: // Data - // ?one_line_short_description_of_data - //?data_declaration; - - private: // Data - - RApaLsSession iApaLsSession; - - CApaCommandLine *iCommandLine; - CRepository *iRepository; - - TSecureId iUsbAppSecureId; - TInt iAskOnConnectionSettingBackup; - TInt iUsbPersonalityBackup; - TInt iTestAskOnConnectionSetting; - TInt iTestUsbPersonality; - - public: // Friend classes - //?friend_class_declaration; - protected: // Friend classes - //?friend_class_declaration; - private: // Friend classes - //?friend_class_declaration; - - }; - -#endif // USBUIAPITEST_H - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/init/USBUiApiTest.ini --- a/usbuis/usbui/tsrc/USBUiApiTest/init/USBUiApiTest.ini Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,218 +0,0 @@ -# -# This is STIF initialization file -# Comment lines start with '#'-character. -# See STIF TestFramework users guide.doc for instructions - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set following test engine settings: -# - Set Test Reporting mode. TestReportMode's possible values are: -# + 'Summary': Summary of the tested test cases. -# + 'Environment': Hardware and software info. -# + 'TestCases': Test case report. -# + 'FullReport': Set of all above ones. -# + Example 'TestReportMode= Summary TestCases' -# -# - CreateTestReport setting controls report creation mode -# + YES, Test report will created. -# + NO, No Test report. -# -# - File path indicates the base path of the test report. -# - File name indicates the name of the test report. -# -# - File format indicates the type of the test report. -# + TXT, Test report file will be txt type, for example 'TestReport.txt'. -# + HTML, Test report will be html type, for example 'TestReport.html'. -# + XML, Test report will be xml type, for example 'TestReport.xml'. -# Note, that xml format is available only when output is set to FILE. -# -# - File output indicates output source of the test report. -# + FILE, Test report logging to file. -# + RDEBUG, Test report logging to using rdebug. -# -# - File Creation Mode indicates test report overwriting if file exist. -# + OVERWRITE, Overwrites if the Test report file exist. -# + APPEND, Continue logging after the old Test report information if -# report exist. -# - Sets a device reset module's dll name(Reboot). -# + If Nokia specific reset module is not available or it is not correct one -# StifHWResetStub module may use as a template for user specific reset -# module. -# - Sets STIF test measurement disable options. e.g. pluging1 and pluging2 disablation -# DisableMeasurement= stifmeasurementplugin01 stifmeasurementplugin02 -# - -[Engine_Defaults] - -TestReportMode= FullReport # Possible values are: 'Empty', 'Summary', 'Environment', - 'TestCases' or 'FullReport' - -CreateTestReport= YES # Possible values: YES or NO - -TestReportFilePath= e:\testing\logs\ -TestReportFileName= USBUiApiTest_TestReport - -TestReportFormat= TXT # Possible values: TXT, HTML or XML -TestReportOutput= FILE # Possible values: FILE or RDEBUG -TestReportFileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -DeviceResetDllName= StifResetForNokia.dll # e.g. 'StifHWResetStub.dll' for user specific reseting - -DisableMeasurement= stifmeasurementdisablenone # Possible values are: - # 'stifmeasurementdisablenone', 'stifmeasurementdisableall' - # 'stifmeasurementplugin01', 'stifmeasurementplugin02', - # 'stifmeasurementplugin03', 'stifmeasurementplugin04', - # 'stifmeasurementplugin05' or 'stifbappeaprofiler' - -Timeout= 0 # Default timeout value for each test case. In milliseconds -UITestingSupport= YES # Possible values: YES or NO -#SeparateProcesses= YES # Possible values: YES or NO (default: NO) -[End_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Module configurations start -# Modules are added between module tags -# tags. Module name is specified after ModuleName= tag, like -# ModuleName= XXXXXXXXX -# Modules might have initialisation file, specified as -# IniFile= c:\testframework\YYYYYY -# Modules might have several configuration files, like -# TestCaseFile= c:\testframework\NormalCases.txt -# TestCaseFile= c:\testframework\SmokeCases.txt -# TestCaseFile= c:\testframework\ManualCases.txt - -# (TestCaseFile is synonym for old term ConfigFile) - -# Following case specifies demo module settings. Demo module -# does not read any settings from file, so tags -# IniFile and TestCaseFile are not used. -# In the simplest case it is enough to specify only the -# name of the test module when adding new test module - -[New_Module] -ModuleName= testscripter -TestCaseFile= e:\testing\conf\ui_USBUiApiTest.cfg -[End_Module] - - -# Load testmoduleXXX, optionally with initialization file and/or test case files -#[New_Module] -#ModuleName= testmodulexxx - -#TestModuleXXX used initialization file -#IniFile= c:\testframework\init.txt - -#TestModuleXXX used configuration file(s) -#TestCaseFile= c:\testframework\testcases1.cfg -#TestCaseFile= c:\testframework\testcases2.cfg -#TestCaseFile= c:\testframework\manualtestcases.cfg - -#[End_Module] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set STIF logging overwrite parameters for Logger. -# Hardware and emulator environment logging path and styles can -# be configured from here to overwrite the Logger's implemented values. -# -# Settings description: -# - Indicates option for creation log directory/directories. If log directory/directories -# is/are not created by user they will make by software. -# + YES, Create log directory/directories if not allready exist. -# + NO, Log directory/directories not created. Only created one is used. -# -# - Overwrite emulator path setting. -# + Example: If 'EmulatorBasePath= C:\LOGS\TestFramework\' and in code is defined -# Logger's path 'D:\\LOGS\\Module\\' with those definition the path -# will be 'C:\LOGS\TestFramework\LOGS\Module\' -# -# - Overwrite emulator's logging format. -# + TXT, Log file(s) will be txt type(s), for example 'Module.txt'. -# + HTML, Log file(s) will be html type(s), for example 'Module.html'. -# -# - Overwrited emulator logging output source. -# + FILE, Logging to file(s). -# + RDEBUG, Logging to using rdebug(s). -# -# - Overwrite hardware path setting (Same description as above in emulator path). -# - Overwrite hardware's logging format(Same description as above in emulator format). -# - Overwrite hardware's logging output source(Same description as above in emulator output). -# -# - File Creation Mode indicates file overwriting if file exist. -# + OVERWRITE, Overwrites if file(s) exist. -# + APPEND, Continue logging after the old logging information if file(s) exist. -# -# - Will thread id include to the log filename. -# + YES, Thread id to log file(s) name, Example filename 'Module_b9.txt'. -# + NO, No thread id to log file(s), Example filename 'Module.txt'. -# -# - Will time stamps include the to log file. -# + YES, Time stamp added to each line in log file(s). Time stamp is -# for example'12.Nov.2003 115958 LOGGING INFO' -# + NO, No time stamp(s). -# -# - Will line breaks include to the log file. -# + YES, Each logging event includes line break and next log event is in own line. -# + NO, No line break(s). -# -# - Will event ranking include to the log file. -# + YES, Event ranking number added to each line in log file(s). Ranking number -# depends on environment's tics, for example(includes time stamp also) -# '012 12.Nov.2003 115958 LOGGING INFO' -# + NO, No event ranking. -# -# - Will write log file in unicode format. -# + YES, Log file will be written in unicode format -# + NO, Log will be written as normal, not unicode, file. -# - -[Logger_Defaults] - -#NOTE: If you want to set Logger using next setting(s) remove comment(s)'#' -#NOTE: TestEngine and TestServer logging settings cannot change here - -#CreateLogDirectories= YES # Possible values: YES or NO - -#EmulatorBasePath= C:\LOGS\TestFramework\ -#EmulatorFormat= HTML # Possible values: TXT or HTML -#EmulatorOutput= FILE # Possible values: FILE or RDEBUG - -#HardwareBasePath= D:\LOGS\TestFramework\ -#HardwareFormat= HTML # Possible values: TXT or HTML -#HardwareOutput= FILE # Possible values: FILE or RDEBUG - -#FileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -#ThreadIdToLogFile= YES # Possible values: YES or NO -#WithTimeStamp= YES # Possible values: YES or NO -#WithLineBreak= YES # Possible values: YES or NO -#WithEventRanking= YES # Possible values: YES or NO - -#FileUnicode= YES # Possible values: YES or NO -#AddTestCaseTitle= YES # Possible values: YES or NO -[End_Logger_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set filters to be used by ConsoleUI. -# If you want to use filter with ConsoleUI, simply remove comments -# from section below and provide valid filter entries. -# Each filter line has to start with "filter= " keyword. -# Filter can contain special wildcard characters: -# * which stands for none or any literal; -# ? which stands for single character. -# Filters are not case-sensitive. - -#[Filters] -#filter= *math* -#filter= *radio* -#[End_Filters] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - -# End of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/init/USBUiApiTest_phone.ini --- a/usbuis/usbui/tsrc/USBUiApiTest/init/USBUiApiTest_phone.ini Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,218 +0,0 @@ -# -# This is STIF initialization file -# Comment lines start with '#'-character. -# See STIF TestFramework users guide.doc for instructions - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set following test engine settings: -# - Set Test Reporting mode. TestReportMode's possible values are: -# + 'Summary': Summary of the tested test cases. -# + 'Environment': Hardware and software info. -# + 'TestCases': Test case report. -# + 'FullReport': Set of all above ones. -# + Example 'TestReportMode= Summary TestCases' -# -# - CreateTestReport setting controls report creation mode -# + YES, Test report will created. -# + NO, No Test report. -# -# - File path indicates the base path of the test report. -# - File name indicates the name of the test report. -# -# - File format indicates the type of the test report. -# + TXT, Test report file will be txt type, for example 'TestReport.txt'. -# + HTML, Test report will be html type, for example 'TestReport.html'. -# + XML, Test report will be xml type, for example 'TestReport.xml'. -# Note, that xml format is available only when output is set to FILE. -# -# - File output indicates output source of the test report. -# + FILE, Test report logging to file. -# + RDEBUG, Test report logging to using rdebug. -# -# - File Creation Mode indicates test report overwriting if file exist. -# + OVERWRITE, Overwrites if the Test report file exist. -# + APPEND, Continue logging after the old Test report information if -# report exist. -# - Sets a device reset module's dll name(Reboot). -# + If Nokia specific reset module is not available or it is not correct one -# StifHWResetStub module may use as a template for user specific reset -# module. -# - Sets STIF test measurement disable options. e.g. pluging1 and pluging2 disablation -# DisableMeasurement= stifmeasurementplugin01 stifmeasurementplugin02 -# - -[Engine_Defaults] - -TestReportMode= FullReport # Possible values are: 'Empty', 'Summary', 'Environment', - 'TestCases' or 'FullReport' - -CreateTestReport= YES # Possible values: YES or NO - -TestReportFilePath= c:\logs\testframework\usb\ -TestReportFileName= testreport - -TestReportFormat= TXT # Possible values: TXT, HTML or XML -TestReportOutput= FILE # Possible values: FILE or RDEBUG -TestReportFileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -DeviceResetDllName= StifResetForNokia.dll # e.g. 'StifHWResetStub.dll' for user specific reseting - -DisableMeasurement= stifmeasurementdisablenone # Possible values are: - # 'stifmeasurementdisablenone', 'stifmeasurementdisableall' - # 'stifmeasurementplugin01', 'stifmeasurementplugin02', - # 'stifmeasurementplugin03', 'stifmeasurementplugin04', - # 'stifmeasurementplugin05' or 'stifbappeaprofiler' - -Timeout= 0 # Default timeout value for each test case. In milliseconds -UITestingSupport= YES # Possible values: YES or NO -#SeparateProcesses= YES # Possible values: YES or NO (default: NO) -[End_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Module configurations start -# Modules are added between module tags -# tags. Module name is specified after ModuleName= tag, like -# ModuleName= XXXXXXXXX -# Modules might have initialisation file, specified as -# IniFile= c:\testframework\YYYYYY -# Modules might have several configuration files, like -# TestCaseFile= c:\testframework\NormalCases.txt -# TestCaseFile= c:\testframework\SmokeCases.txt -# TestCaseFile= c:\testframework\ManualCases.txt - -# (TestCaseFile is synonym for old term ConfigFile) - -# Following case specifies demo module settings. Demo module -# does not read any settings from file, so tags -# IniFile and TestCaseFile are not used. -# In the simplest case it is enough to specify only the -# name of the test module when adding new test module - -[New_Module] -ModuleName= testscripter -TestCaseFile= c:\testframework\ui_USBUiApiTest.cfg -[End_Module] - - -# Load testmoduleXXX, optionally with initialization file and/or test case files -#[New_Module] -#ModuleName= testmodulexxx - -#TestModuleXXX used initialization file -#IniFile= c:\testframework\init.txt - -#TestModuleXXX used configuration file(s) -#TestCaseFile= c:\testframework\testcases1.cfg -#TestCaseFile= c:\testframework\testcases2.cfg -#TestCaseFile= c:\testframework\manualtestcases.cfg - -#[End_Module] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set STIF logging overwrite parameters for Logger. -# Hardware and emulator environment logging path and styles can -# be configured from here to overwrite the Logger's implemented values. -# -# Settings description: -# - Indicates option for creation log directory/directories. If log directory/directories -# is/are not created by user they will make by software. -# + YES, Create log directory/directories if not allready exist. -# + NO, Log directory/directories not created. Only created one is used. -# -# - Overwrite emulator path setting. -# + Example: If 'EmulatorBasePath= C:\LOGS\TestFramework\' and in code is defined -# Logger's path 'D:\\LOGS\\Module\\' with those definition the path -# will be 'C:\LOGS\TestFramework\LOGS\Module\' -# -# - Overwrite emulator's logging format. -# + TXT, Log file(s) will be txt type(s), for example 'Module.txt'. -# + HTML, Log file(s) will be html type(s), for example 'Module.html'. -# -# - Overwrited emulator logging output source. -# + FILE, Logging to file(s). -# + RDEBUG, Logging to using rdebug(s). -# -# - Overwrite hardware path setting (Same description as above in emulator path). -# - Overwrite hardware's logging format(Same description as above in emulator format). -# - Overwrite hardware's logging output source(Same description as above in emulator output). -# -# - File Creation Mode indicates file overwriting if file exist. -# + OVERWRITE, Overwrites if file(s) exist. -# + APPEND, Continue logging after the old logging information if file(s) exist. -# -# - Will thread id include to the log filename. -# + YES, Thread id to log file(s) name, Example filename 'Module_b9.txt'. -# + NO, No thread id to log file(s), Example filename 'Module.txt'. -# -# - Will time stamps include the to log file. -# + YES, Time stamp added to each line in log file(s). Time stamp is -# for example'12.Nov.2003 115958 LOGGING INFO' -# + NO, No time stamp(s). -# -# - Will line breaks include to the log file. -# + YES, Each logging event includes line break and next log event is in own line. -# + NO, No line break(s). -# -# - Will event ranking include to the log file. -# + YES, Event ranking number added to each line in log file(s). Ranking number -# depends on environment's tics, for example(includes time stamp also) -# '012 12.Nov.2003 115958 LOGGING INFO' -# + NO, No event ranking. -# -# - Will write log file in unicode format. -# + YES, Log file will be written in unicode format -# + NO, Log will be written as normal, not unicode, file. -# - -[Logger_Defaults] - -#NOTE: If you want to set Logger using next setting(s) remove comment(s)'#' -#NOTE: TestEngine and TestServer logging settings cannot change here - -#CreateLogDirectories= YES # Possible values: YES or NO - -#EmulatorBasePath= C:\LOGS\TestFramework\ -#EmulatorFormat= HTML # Possible values: TXT or HTML -#EmulatorOutput= FILE # Possible values: FILE or RDEBUG - -#HardwareBasePath= D:\LOGS\TestFramework\ -#HardwareFormat= HTML # Possible values: TXT or HTML -#HardwareOutput= FILE # Possible values: FILE or RDEBUG - -#FileCreationMode= OVERWRITE # Possible values: OVERWRITE or APPEND - -#ThreadIdToLogFile= YES # Possible values: YES or NO -#WithTimeStamp= YES # Possible values: YES or NO -#WithLineBreak= YES # Possible values: YES or NO -#WithEventRanking= YES # Possible values: YES or NO - -#FileUnicode= YES # Possible values: YES or NO -#AddTestCaseTitle= YES # Possible values: YES or NO -[End_Logger_Defaults] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - - - -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -# Set filters to be used by ConsoleUI. -# If you want to use filter with ConsoleUI, simply remove comments -# from section below and provide valid filter entries. -# Each filter line has to start with "filter= " keyword. -# Filter can contain special wildcard characters: -# * which stands for none or any literal; -# ? which stands for single character. -# Filters are not case-sensitive. - -#[Filters] -#filter= *math* -#filter= *radio* -#[End_Filters] -# -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- - -# End of file diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/src/USBUiApiTest.cpp --- a/usbuis/usbui/tsrc/USBUiApiTest/src/USBUiApiTest.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,205 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - -// INCLUDE FILES -#include -#include "USBUiApiTest.h" -#include - -// EXTERNAL DATA STRUCTURES -//extern ?external_data; - -// EXTERNAL FUNCTION PROTOTYPES -//extern ?external_function( ?arg_type,?arg_type ); - -// CONSTANTS -//const ?type ?constant_var = ?constant; - -// MACROS -//#define ?macro ?macro_def - -// LOCAL CONSTANTS AND MACROS -//const ?type ?constant_var = ?constant; -//#define ?macro_name ?macro_def - -// MODULE DATA STRUCTURES -//enum ?declaration -//typedef ?declaration - -// LOCAL FUNCTION PROTOTYPES -//?type ?function_name( ?arg_type, ?arg_type ); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; - -// ============================= LOCAL FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// ?function_name ?description. -// ?description -// Returns: ?value_1: ?description -// ?value_n: ?description_line1 -// ?description_line2 -// ----------------------------------------------------------------------------- -// -/* -?type ?function_name( - ?arg_type arg, // ?description - ?arg_type arg) // ?description - { - - ?code // ?comment - - // ?comment - ?code - } -*/ - -// ============================ MEMBER FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::CUSBUiApiTest -// C++ default constructor can NOT contain any code, that -// might leave. -// ----------------------------------------------------------------------------- -// -CUSBUiApiTest::CUSBUiApiTest( - CTestModuleIf& aTestModuleIf ): - CScriptBase( aTestModuleIf ) - { - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::ConstructL -// Symbian 2nd phase constructor can leave. -// ----------------------------------------------------------------------------- -// -void CUSBUiApiTest::ConstructL() - { - //Read logger settings to check whether test case name is to be - //appended to log file name. - RSettingServer settingServer; - TInt ret = settingServer.Connect(); - if(ret != KErrNone) - { - User::Leave(ret); - } - // Struct to StifLogger settigs. - TLoggerSettings loggerSettings; - // Parse StifLogger defaults from STIF initialization file. - ret = settingServer.GetLoggerSettings(loggerSettings); - if(ret != KErrNone) - { - User::Leave(ret); - } - // Close Setting server session - settingServer.Close(); - - TFileName logFileName; - - if(loggerSettings.iAddTestCaseTitle) - { - TName title; - TestModuleIf().GetTestCaseTitleL(title); - logFileName.Format(KUSBUiApiTestLogFileWithTitle, &title); - } - else - { - logFileName.Copy(KUSBUiApiTestLogFile); - } - - iLog = CStifLogger::NewL( KUSBUiApiTestLogPath, - logFileName, - CStifLogger::ETxt, - CStifLogger::EFile, - EFalse ); - - SendTestClassVersion(); - - iCommandLine = CApaCommandLine::NewL(); - iUsbAppSecureId = TSecureId( KUidUSBClassChangeUI ); - iRepository = CRepository::NewL( KCRUidUsbWatcher ); - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::NewL -// Two-phased constructor. -// ----------------------------------------------------------------------------- -// -CUSBUiApiTest* CUSBUiApiTest::NewL( - CTestModuleIf& aTestModuleIf ) - { - CUSBUiApiTest* self = new (ELeave) CUSBUiApiTest( aTestModuleIf ); - - CleanupStack::PushL( self ); - self->ConstructL(); - CleanupStack::Pop(); - - return self; - - } - -// Destructor -CUSBUiApiTest::~CUSBUiApiTest() - { - - // Delete resources allocated from test methods - Delete(); - - // Delete logger - delete iLog; - - } - -//----------------------------------------------------------------------------- -// CUSBUiApiTest::SendTestClassVersion -// Method used to send version of test class -//----------------------------------------------------------------------------- -// -void CUSBUiApiTest::SendTestClassVersion() - { - TVersion moduleVersion; - moduleVersion.iMajor = TEST_CLASS_VERSION_MAJOR; - moduleVersion.iMinor = TEST_CLASS_VERSION_MINOR; - moduleVersion.iBuild = TEST_CLASS_VERSION_BUILD; - - TFileName moduleName; - moduleName = _L("USBUiApiTest.dll"); - - TBool newVersionOfMethod = ETrue; - TestModuleIf().SendTestModuleVersion(moduleVersion, moduleName, newVersionOfMethod); - } - -// ========================== OTHER EXPORTED FUNCTIONS ========================= - -// ----------------------------------------------------------------------------- -// LibEntryL is a polymorphic Dll entry point. -// Returns: CScriptBase: New CScriptBase derived object -// ----------------------------------------------------------------------------- -// -EXPORT_C CScriptBase* LibEntryL( - CTestModuleIf& aTestModuleIf ) // Backpointer to STIF Test Framework - { - - return ( CScriptBase* ) CUSBUiApiTest::NewL( aTestModuleIf ); - - } - - -// End of File diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbui/tsrc/USBUiApiTest/src/USBUiApiTestBlocks.cpp --- a/usbuis/usbui/tsrc/USBUiApiTest/src/USBUiApiTestBlocks.cpp Thu Jan 07 13:25:34 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,493 +0,0 @@ -/* -* Copyright (c) 2002 - 2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "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: ?Description -* -*/ - - - -// [INCLUDE FILES] - do not remove -#include -#include -#include -#include "USBUiApiTest.h" - -// EXTERNAL DATA STRUCTURES -//extern ?external_data; - -// EXTERNAL FUNCTION PROTOTYPES -//extern ?external_function( ?arg_type,?arg_type ); - -// CONSTANTS -//const ?type ?constant_var = ?constant; - -// MACROS -//#define ?macro ?macro_def - -// LOCAL CONSTANTS AND MACROS -//const ?type ?constant_var = ?constant; -//#define ?macro_name ?macro_def - -// MODULE DATA STRUCTURES -//enum ?declaration -//typedef ?declaration - -// LOCAL FUNCTION PROTOTYPES -//?type ?function_name( ?arg_type, ?arg_type ); - -// FORWARD DECLARATIONS -//class ?FORWARD_CLASSNAME; - -// ============================= LOCAL FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// ?function_name ?description. -// ?description -// Returns: ?value_1: ?description -// ?value_n: ?description_line1 -// ?description_line2 -// ----------------------------------------------------------------------------- -// -/* -?type ?function_name( - ?arg_type arg, // ?description - ?arg_type arg) // ?description - { - - ?code // ?comment - - // ?comment - ?code - } -*/ - -// ============================ MEMBER FUNCTIONS =============================== - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::Delete -// Delete here all resources allocated and opened from test methods. -// Called from destructor. -// ----------------------------------------------------------------------------- -// -void CUSBUiApiTest::Delete() - { - iApaLsSession.Close(); - delete iCommandLine; - iCommandLine = NULL; - delete iRepository; - iRepository = NULL; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::RunMethodL -// Run specified method. Contains also table of test mothods and their names. -// ----------------------------------------------------------------------------- -// -TInt CUSBUiApiTest::RunMethodL( - CStifItemParser& aItem ) - { - - static TStifFunctionInfo const KFunctions[] = - { - // Copy this line for every implemented function. - // First string is the function name used in TestScripter script file. - // Second is the actual implementation member function. - ENTRY( "LaunchUsbUiApp", CUSBUiApiTest::LaunchUsbUiApp ), - ENTRY( "FinishTest", CUSBUiApiTest::FinishTest ), - ENTRY( "TurnLightsOn", CUSBUiApiTest::TurnLightsOn ), - //ADD NEW ENTRY HERE - // [test cases entries] - Do not remove - - }; - - const TInt count = sizeof( KFunctions ) / - sizeof( TStifFunctionInfo ); - - return RunInternalL( KFunctions, count, aItem ); - - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::LaunchUsbUiApp -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::LaunchUsbUiApp( CStifItemParser& aItem ) - { - TInt res; - TPtrC testAskOnConnectionSettingName( KNullDesC ); - TPtrC testUsbPersonalityName( KNullDesC ); - TInt testAskOnConnectionSetting; - TInt testUsbPersonalityId; - - res = aItem.GetString( _L( "LaunchUsbUiApp" ), testAskOnConnectionSettingName ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - //STIF_LOG("aItem.GetString testAskOnConnectionSettingName OK"); - - res = GetAskOnConnectionOptionFromString( testAskOnConnectionSettingName, testAskOnConnectionSetting ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetAskOnConnectionOptionFromString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - //STIF_LOG1("GetAskOnConnectionOptionFromString OK: %d", testAskOnConnectionSetting); - - res = aItem.GetNextString( testUsbPersonalityName ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetNextString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - //STIF_LOG("aItem.GetNextString testUsbPersonalityName OK"); - - res = GetUsbPersonalityOptionFromString( testUsbPersonalityName, testUsbPersonalityId ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetUsbPersonalityOptionFromString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - //STIF_LOG1("GetUsbPersonalityOptionFromString OK: %d",testUsbPersonalityId); - - res = GetUsbSettings( iUsbPersonalityBackup, iAskOnConnectionSettingBackup ); - if ( res != KErrNone ) - { - iLog -> Log( _L("Failed to backup usb settings with value: %d"), res ); - return res; - } - STIF_LOG2("GetUsbSettings OK: %d, %d", iUsbPersonalityBackup, iAskOnConnectionSettingBackup); - - res = SetUsbSettings( testUsbPersonalityId, testAskOnConnectionSetting ); - if ( res != KErrNone ) - { - iLog -> Log( _L("Changing usb settings failed with value (cenrep): %d"), res ); - return res; - } - STIF_LOG2("SetUsbSettings OK: %d, %d", testUsbPersonalityId, testAskOnConnectionSetting); - - iCommandLine->SetCommandL( EApaCommandRun ); - iCommandLine->SetExecutableNameL( KUsbAppFileName ); - - res = iApaLsSession.Connect(); - if ( res != KErrNone ) - { - iLog->Log( _L("Connecting to application server failed with value: %d"), res ); - return res; - } - STIF_LOG("iApaLsSession.Connect OK"); - - res = iApaLsSession.StartApp( *iCommandLine ); - if ( res != KErrNone ) - { - iLog->Log( _L("Starting application failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG("iApaLsSession.StartApp OK"); - - if ( !IsUsbAppRunning() ) - { - iLog->Log( _L("Usb application launch error") ); - iApaLsSession.Close(); - return KErrGeneral; - } - STIF_LOG("IsUsbAppRunning OK"); - - iLog->Log( _L("Usb application started") ); - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::FinishTest -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::FinishTest( CStifItemParser& aItem ) - { - TInt res; - TPtrC optionName( KNullDesC ); - TUSBAppTestOption option; - TBool isAppRunning; - TPtrC expectedAskOnConnectionSettingName( KNullDesC ); - TPtrC expectedPersonalityIdSettingName( KNullDesC ); - TInt actualAskOnConnectionSetting; - TInt expectedAskOnConnectionSetting; - TInt actualPersonalityIdSetting; - TInt expectedPersonalityIdSetting; - - res = aItem.GetString( _L( "FinishTest" ), optionName ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG("aItem.GetString optionName OK"); - - res = GetTestOption( optionName, option ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetTestOption failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG1("GetTestOption OK: %d",option); - - if ( option == EAskOnConnectionSettingChanged || option == EUsbConnectionModeSettingChanged ) - { - res = aItem.GetNextString( expectedAskOnConnectionSettingName ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetNextString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG("aItem.GetNextString expectedAskOnConnectionSettingName OK"); - - res = GetAskOnConnectionOptionFromString( expectedAskOnConnectionSettingName, expectedAskOnConnectionSetting ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetAskOnConnectionOptionFromString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG1("GetAskOnConnectionOptionFromString OK: %d", expectedAskOnConnectionSetting); - - res = aItem.GetNextString( expectedPersonalityIdSettingName ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetNextString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG("aItem.GetNextString expectedPersonalityIdSettingName OK"); - - res = GetUsbPersonalityOptionFromString( expectedPersonalityIdSettingName, expectedPersonalityIdSetting ); - if ( res != KErrNone ) - { - iLog -> Log( _L("GetUsbPersonalityOptionFromString failed with value: %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG1("GetUsbPersonalityOptionFromString OK %d", expectedPersonalityIdSetting); - } - - isAppRunning = IsUsbAppRunning(); - - res = GetUsbSettings( actualPersonalityIdSetting, actualAskOnConnectionSetting ); - if ( res != KErrNone ) - { - iLog -> Log( _L("Getting usb settings failed with value (cenrep): %d"), res ); - iApaLsSession.Close(); - return res; - } - STIF_LOG2("GetUsbSettings OK: %d, %d", actualPersonalityIdSetting, actualAskOnConnectionSetting); - - res = SetUsbSettings( iUsbPersonalityBackup, iAskOnConnectionSettingBackup ); - if ( res != KErrNone ) - iLog -> Log( _L("Failed to restore original usb settings!") ); - STIF_LOG2("SetUsbSettings OK: %d, %d", iUsbPersonalityBackup, iAskOnConnectionSettingBackup); - - iApaLsSession.Close(); - - switch( option ) - { - case EAskOnConnectionSettingChanged: - case EUsbConnectionModeSettingChanged: - iLog -> Log( _L("Actual USB ask on connection setting value: %d, expected: %d"), actualAskOnConnectionSetting, expectedAskOnConnectionSetting ); - STIF_ASSERT_EQUALS( expectedAskOnConnectionSetting, actualAskOnConnectionSetting ); - iLog -> Log( _L("Actual USB personality setting value: %d, expected: %d"), actualPersonalityIdSetting, expectedPersonalityIdSetting ); - STIF_ASSERT_EQUALS( expectedPersonalityIdSetting, actualPersonalityIdSetting ); - iLog -> Log( _L("USB app is running: %d, expected: %d"), isAppRunning, EFalse ); - STIF_ASSERT_FALSE( isAppRunning ); - break; - case EAppCancelled: - iLog -> Log( _L("USB app is running: %d, expected: %d"), isAppRunning, EFalse ); - STIF_ASSERT_FALSE( isAppRunning ); - break; - default: - return KErrNotFound; - } - - iLog -> Log( _L("Test case passed!") ); - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::FinishTest -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::GetTestOption( TPtrC aOptionString, TUSBAppTestOption& aOption ) - { - if ( !aOptionString.Compare( _L( "USB_CONN_MODE" ) ) ) - { - aOption = EUsbConnectionModeSettingChanged; - iLog -> Log( _L("Test type: EUsbConnectionModeSettingChanged") ); - } - else if ( !aOptionString.Compare( _L( "ASK_ON_CONN" ) ) ) - { - aOption = EAskOnConnectionSettingChanged; - iLog -> Log( _L("Test type: EAskOnConnectionSettingChanged") ); - } - else if ( !aOptionString.Compare( _L( "CANCELLED" ) ) ) - { - aOption = EAppCancelled; - iLog -> Log( _L("Test type: EAppCancelled") ); - } - else - { - iLog -> Log( _L("Test type: not supported") ); - return KErrNotFound; - } - - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::GetAskOnConnectionOptionFromString -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::GetAskOnConnectionOptionFromString( TPtrC aOptionString, TInt& aOption ) - { - if ( !aOptionString.Compare( _L( "ON" ) ) ) - { - aOption = KUsbWatcherChangeOnConnectionOn; - iLog -> Log( _L("Ask on connection option: ON") ); - } - else if ( !aOptionString.Compare( _L( "OFF" ) ) ) - { - aOption = KUsbWatcherChangeOnConnectionOff; - iLog -> Log( _L("Ask on connection option: OFF") ); - } - else - { - iLog -> Log( _L("Ask on connection option: not supported") ); - return KErrNotFound; - } - - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::GetUsbPersonalityOptionFromString -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::GetUsbPersonalityOptionFromString( TPtrC aOptionString, TInt& aOption ) - { - if ( !aOptionString.Compare( _L( "PCSUITE" ) ) ) - { - aOption = KUsbPersonalityIdPCSuiteMTP; - iLog -> Log( _L("Usb personality option: KUsbPersonalityIdPCSuiteMTP") ); - } - else if ( !aOptionString.Compare( _L( "MS" ) ) ) - { - aOption = KUsbPersonalityIdMS; - iLog -> Log( _L("Usb personality option: KUsbPersonalityIdMS") ); - } - else if ( !aOptionString.Compare( _L( "PTP" ) ) ) - { - aOption = KUsbPersonalityIdPTP; - iLog -> Log( _L("Usb personality option: KUsbPersonalityIdPTP") ); - } - else if ( !aOptionString.Compare( _L( "MTP" ) ) ) - { - aOption = KUsbPersonalityIdMTP; - iLog -> Log( _L("Usb personality option: KUsbPersonalityIdMTP") ); - } - else - { - iLog -> Log( _L("Usb personality option: not supported") ); - return KErrNotFound; - } - - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::IsUsbAppRunning -// ----------------------------------------------------------------------------- - -TBool CUSBUiApiTest::IsUsbAppRunning() - { - TFindProcess processFinder; - TFullName processName; - TBool isAppRunning = EFalse; - RProcess matchedProcess; - - while ( processFinder.Next( processName ) == KErrNone ) - { - matchedProcess.Open( processFinder ); - if ( matchedProcess.SecureId() == iUsbAppSecureId ) - isAppRunning = ETrue; - } - - matchedProcess.Close(); - return isAppRunning; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::GetUsbSettings -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::GetUsbSettings( TInt& aUsbPersonalityId, TInt& aAskOnConnectionSetting ) - { - TInt res; - res = iRepository -> Get( KUsbWatcherChangeOnConnectionSetting, aAskOnConnectionSetting ); - if ( res != KErrNone ) - return res; - - res = iRepository -> Get( KUsbWatcherPersonality, aUsbPersonalityId ); - if ( res != KErrNone ) - return res; - - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::SetUsbSettings -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::SetUsbSettings( TInt aUsbPersonalityId, TInt aAskOnConnectionSetting ) - { - TInt res; - res = iRepository -> Set( KUsbWatcherChangeOnConnectionSetting, aAskOnConnectionSetting ); - if ( res != KErrNone ) - return res; - - res = iRepository -> Set( KUsbWatcherPersonality, aUsbPersonalityId ); - if ( res != KErrNone ) - return res; - - return KErrNone; - } - -// ----------------------------------------------------------------------------- -// CUSBUiApiTest::TurnLightsOn -// ----------------------------------------------------------------------------- - -TInt CUSBUiApiTest::TurnLightsOn( CStifItemParser& aItem ) - { - TInt res; - res = RProperty::Set(KPSUidCoreApplicationUIs, KLightsControl, ELightsOn); - return res; - } -// ========================== OTHER EXPORTED FUNCTIONS ========================= -// None - -// [End of File] - Do not remove diff -r 705ec7b86991 -r 468cfcb53fd1 usbuis/usbuinotif/inc/usbnotifier.h --- a/usbuis/usbuinotif/inc/usbnotifier.h Thu Jan 07 13:25:34 2010 +0200 +++ b/usbuis/usbuinotif/inc/usbnotifier.h Mon Jan 18 21:13:23 2010 +0200 @@ -23,7 +23,7 @@ #include #include #include -#include "USBUINotifDebug.h" +#include "usbuinotifdebug.h" // CONSTANTS // Literal resource filename _LIT(KResourceFileName, "usbuinotif.rsc");