BT-USER API Test Suite

This section describes BT-USER Test Suite. It provides an overview of the test suite, its coverage, how to set up the test environment to execute the test suite, and how to find further information about the test cases offered by this test suite.

The aim of the BT-USER Test Suite is to provide and deliver a product quality set of test suites that can be used internally within Symbian, and by external groups who have access to the Symbian test source code.

BLUETOOTH-USER component Test Suite

Test Suite overview

The BLUETOOTH_USER Test Suite is grouped into three sub-suites:

These sub-suites contain several regression tests for the classes stated in the following table:

T_BTUserAPI T_BTSockAPI T_BTSockAddrAPI

CBluetoothPhysicalLinks

CBluetoothSocket

TSockAddr

CBluetoothSynchronousLink

 

TBTSockAddr

TBTAccessRequirements

 

TRfcommSockAddr

RBTPhysicalLinkAdapter

   

TBTSyncBandwidth

   

TBTSyncPackets

   

TInquirySockAddr

   

TL2CapConfig

   

TL2CAPSockAddr

   

TRfcommRemotePortParams

   

TRfcommRPNTransaction

   

TBTServiceSecurity

   

All APIs that Symbian classify as PublishedAll are tested within each class.

Test approach

The test suite is a means of confidence that the APIs work as expected. Negative testing is performed wherever it is needed, to confirm that correct errors are returned when incorrect parameters are given.

The following test scripts require user interaction (entering passkey) during test execution:

  • BT-USER-AccessRequirements-PublicApi-Active-Master.script

  • BT-USER-PhysicalLinkAdapter-PublicApi-Active-Master.script

The other test scripts are completely automated.

Coverage omissions

The following two CBluetoothSocket APIs are omitted from this test suite:

  • CBluetoothSocket* CBluetoothSocket::NewL(MBluetoothSocketNotifier &aNotifier, RSocketServ &aServer, TUint aSockType, TUint aProtocol, RConnection &aConnection);

  • CBluetoothSocket* CBluetoothSocket::NewLC(MBluetoothSocketNotifier &aNotifier, RSocketServ &aServer, TUint aSockType, TUint aProtocol, RConnection &aConnection);

This is because these constructors cannot be used as it is currently impossible to add a CBluetoothSocket to a Bluetooth RConnection. All other constructors are tested in this suite.

The following CBluetoothSocket APIs are not fully tested in this test suite:

  • TInt CBluetoothSocket::RecvFrom(TDes8 &aDesc, TSockAddr &aSockAddr, TUint flags);

  • TInt CBluetoothSocket::RecvFrom(TDes8 &aDesc, TSockAddr &aSockAddr, TUint flags, TSockXfrLength &aLen);

  • TInt CBluetoothSocket::SendTo(const TDesC8 &aDesc, TSockAddr &aSockAddr, TUint flags);

  • TInt CBluetoothSocket::SendTo(const TDesC8 &aDesc, TSockAddr &aSockAddr, TUint flags, TSockXfrLength &aLen);

This is because Symbian has no connectionless Bluetooth, which these APIs use. The tests calling these APIs therefore expect them to return the error code KErrNotReady.

The following four CBluetoothSynchronousLink APIs are omitted from this test suite:

  • TInt CBluetoothSynchronousLink::Send(const TDesC8 &aData);

  • TInt CBluetoothSynchronousLink::Receive(TDes8 &aData);

  • void CBluetoothSynchronousLink::CancelReceive();

  • void CBluetoothSynchronousLink::CancelSend();

This is due to hardware dependency.

The following eight CBluetoothSynchronousLink APIs are not fully tested in this test suite:

  • void CBluetoothSynchronousLink::SetCoding(TUint16 aVoiceSetting);

  • void CBluetoothSynchronousLink::SetMaxBandwidth(TBTSyncBandwidth aMaximum);

  • void CBluetoothSynchronousLink::SetMaxLatency(TUint16 aLatency);

  • void CBluetoothSynchronousLink::SetRetransmissionEffort(TBTeSCORetransmissionTypes aRetransmissionEffort);

  • TUint16 CBluetoothSynchronousLink::Coding();

  • TBTSyncBandwidth CBluetoothSynchronousLink::Bandwidth();

  • TUint16 CBluetoothSynchronousLink::Latency();

  • TUint8 CBluetoothSynchronousLink::RetransmissionEffort();

This is due to hardware dependency.

Test Suite details

Test script source tree location

Descriptions of the test cases can be found in the following location:

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-AccessRequirements-PublicApi-Active-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-AccessRequirements-PublicApi-Active-Master-Auto.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-AccessRequirements-PublicApi-Passive-Slave.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-AccessRequirements-PublicApi-Passive-Slave-Auto.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BluetoothPhysicalLinks-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BluetoothSynchronousLink-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BTAccessRequirements-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BTPhysicalLinkAdapter-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BTSyncBandWidth-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-BTSyncPackets-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-InquirySockAddr-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-L2CapConfig-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-L2CapSockAddr-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinkAdapter-PublicApi-Active-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinkAdapter-PublicApi-Active-Master-Auto.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinkAdapter-PublicApi-Passive-Slave.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinkAdapter-PublicApi-Passive-Slave-Auto.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinks-PublicApi-Active-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-PhysicalLinks-PublicApi-Passive-Slave.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-RfcommRemotePortParams-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-RfcommRPNTransaction-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-SynchronousLink-PublicApi-Active-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\scripts\BT-USER-SynchronousLink-PublicApi-Passive-Slave.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAddrAPI\scripts\BT-SOCK-ADDR-PublicApi.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\scripts\BT-USER-SOCK-PublicApi-Unconnected.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\scripts\BT-USER-SOCK-PublicApi-Active-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\scripts\BT-USER-SOCK-PublicApi-Active-Slave.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\scripts\BT-USER-SOCK-PublicApi-Passive-Master.script

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\scripts\BT-USER-SOCK-PublicApi-Passive-Slave.script

Test script EPOC tree location

When the tests are built, the scripts are first exported into the following locations in the EPOC tree:

  • T_BTSockAPI and T_BTSockAddrAPI scripts:

    %EPOCROOT%\epoc32\data\Z\bluetooth\

  • T_BTUserAPI scripts:

    %EPOCROOT%\epoc32\data\Z\bluetooth\user\

Note: Any mention of “epoc32” is offset by %EPOCROOT%; that is, the full path where the EPOC tree is installed.

Test script build location

When the tests are built, the scripts are built into the following locations:

  • T_BTSockAPI and T_BTSockAddrAPI scripts: %EPOCROOT%\epoc32\release\<winscw|armv5>\<udeb|urel>\Z\bluetooth\

  • T_BTUserAPI scripts: %EPOCROOT%\epoc32\release\<winscw|armv5>\<udeb|urel>\Z\bluetooth\user\

Note: When the tests are built to be executed on hardware the files are built into the z: drive of the ROM.

Test data source tree location

The test data files can be found in the following location:

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-AccessRequirements-PublicApi-Active-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-AccessRequirements-PublicApi-Active-Master-Auto.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-AccessRequirements-PublicApi-Passive-Slave.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-AccessRequirements-PublicApi-Passive-Slave-Auto.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BluetoothPhysicalLinks-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BluetoothSynchronousLink-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BTAccessRequirements-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BTPhysicalLinkAdapter-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BTSyncBandWidth-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-BTSyncPackets-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-InquirySockAddr-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-L2CapConfig-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-L2CapSockAddr-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinkAdapter-PublicApi-Active-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinkAdapter-PublicApi-Active-Master-Auto.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinkAdapter-PublicApi-Passive-Slave.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinkAdapter-PublicApi-Passive-Slave-Auto.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinks-PublicApi-Active-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-PhysicalLinks-PublicApi-Passive-Slave.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-RfcommRemotePortParams-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-RfcommRPNTransaction-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-SynchronousLink-PublicApi-Active-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTUserAPI\testdata\BT-USER-SynchronousLink-PublicApi-Passive-Slave.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAddrAPI\testdata\BT-SOCK-ADDR-PublicApi.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\testdata\BT-USER-SOCK-PublicApi-Unconnected.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\testdata\BT-USER-SOCK-PublicApi-Active-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\testdata\BT-USER-SOCK-PublicApi-Passive-Master.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\testdata\BT-USER-SOCK-PublicApi-Passive-Slave.ini

  • ...\bluetoothapitest\bluetoothsvs\T_BTSockAPI\testdata\BT-USER-SOCK-PublicApi-Active-Slave.ini

Test data EPOC tree location

When the tests are built, the test data files are first exported into the following location in the EPOC tree:

  • T_BTSockAPI and T_BTSockAddrAPI test data:

    %EPOCROOT%\epoc32\data\Z\bluetooth\

  • T_BTUserAPI test data:

    %EPOCROOT%\epoc32\data\Z\bluetooth\user\

Test data build location

When the tests are built, the test data files are built into the following location:

  • T_BTSockAPI and T_BTSockAddrAPI test data:

    %EPOCROOT%\epoc32\release\<winscw|armv5>\<udeb|urel>\Z\bluetooth\

  • T_BTUserAPI test data:

    %EPOCROOT%\epoc32\release\<winscw|armv5>\<udeb|urel>\Z\bluetooth\user\

Note: When the tests are built to be executed on hardware the files are built into the z: drive of the ROM.

Test .driver file

The bluetooth.driver file found in the following location:

…\bluetoothapitest\bluetoothsvs\testsuites\bluetooth

This file is used by the test driver to construct the test suite tree structure and export all the appropriate files to the correct location in the epoc32 tree and on the device.

When the tests are built, the .driver file is built into the following location:

%EPOCROOT%\epoc32\testdriver\testproduct

TCS file source location

The .tcs file can be found in the following location:

...\bluetoothapitest\bluetoothsvs\config\t_bluetooth.tcs

TCS files build location

When the tests are built, the .tcs file is built into the following location:

t_bluetooth.tcs: %EPOCROOT%\epoc32\release\<winscw|armv5>\<udeb|urel>\Z\bluetooth\

Note: When the tests are built to be executed on the hardware, the files are built into the z: drive of the ROM.

Test environment and execution

Device setup

See Bluetooth Test Technology for further information regarding test environment and build and execution procedure.

Support

For support issues related to this Test Suite description and issues to running the tests, test pass rates, and potential defects, contact Symbian or your SDK provider. In most instances, this will be either through the Symbian technical consulting teams, the SDK provider forums or through the developer area of Symbian website.