Trying to figure out how to implement my WINC like compatibility layer. Going the emulation way is probably not so smart. We should not use the kernel but rather hook native functions in the Exec calls.
// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of the License "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
// Interopeablily between the device under test and a PC via USB
//
//
//! @file btsdwp.script
//! @SYMTestSuiteName basetestsd
//! @SYMScriptTestEnvironment base
LOAD_SUITE basetestsd
PRINT ATTENTION: This is a manual test
PRINT The device under test must be connected to a host PC via a USB cable
PRINT User will be prompted to perform file operations on the host PC via the mass-storage mechanism
START_TESTCASE PBASE-INTEROPUSBOUTBOUND-0211
//! @SYMTestCaseID PBASE-INTEROPUSBOUTBOUND-0211
//! @SYMTestCaseDesc File system interoperability from the device under test to a host PC via USB
//! @SYMREQ REQ0000
//! @SYMTestActions
//! 1. Format card
//! 2. Create several files and directories
//! 3. Read files on the card
//! 4. Enable the Mass Storage Mode
//! 5. User reads contents of the memory card from the host PC
//! 6. User performs some more file operations from the host PC
//! 7. User disconnects the USB device
//! 8. Read files on the card
//! 9. Check file system for consistency
//! @SYMTestExpectedResults
//! 1. No error
//! 2. No error
//! 3. Memory card contents are exactly as expected
//! 4. Memory card appears on the host PC as a remote drive
//! 5. Memory card contents are exactly as expected
//! 6. No error
//! 7. No error and test execution resumes on the device under test
//! 8. Memory card contents are exactly as expected
//! 9. File system is not corrupt
//! @SYMTestPriority High
//! @SYMTestStatus Implemented
//! @SYMTestType CIT
RUN_TEST_STEP 500 basetestsd Format \basetest\btsd.ini FullFormat
RUN_TEST_STEP 2000 basetestsd FileOperations1 \basetest\btsd.ini INTEROP_OUTBOUND
RUN_TEST_STEP 500 basetestsd ReadFiles1 \basetest\btsd.ini INTEROP_OUTBOUND
RUN_TEST_STEP -1 basetestsd DialogBox \basetest\btsd.ini INTEROPUSB_OUTBOUND
RUN_TEST_STEP -1 basetestsd USB \basetest\btsd.ini
RUN_TEST_STEP 500 basetestsd ReadFiles2 \basetest\btsd.ini INTEROP_OUTBOUND
RUN_TEST_STEP 500 basetestsd CheckDisk \basetest\btsd.ini
END_TESTCASE PBASE-INTEROPUSBOUTBOUND-0211
START_TESTCASE PBASE-INTEROPUSBINBOUND-0212
//! @SYMTestCaseID PBASE-INTEROPUSBINBOUND-0212
//! @SYMTestCaseDesc File system interoperability from a host PC to the device under test via USB
//! @SYMREQ REQ0000
//! @SYMTestActions
//! 1. Format card
//! 2. Enable the Mass Storage Mode
//! 3. User performs specific file operations from the host PC
//! 4. User disconnects the USB device
//! 5. Read files on the card
//! 6. Create several files and directories
//! 7. Read files on the card
//! 8. Check file system for consistency
//! @SYMTestExpectedResults
//! 1. No error
//! 2. Memory card appears on the host PC as an empty remote drive
//! 3. No error
//! 4. No error and test execution resumes on the device under test
//! 5. Memory card contents are exactly as expected
//! 6. No error
//! 7. Memory card contents are exactly as expected
//! 8. File system is not corrupt
//! @SYMTestPriority High
//! @SYMTestStatus Implemented
//! @SYMTestType CIT
RUN_TEST_STEP -1 basetestsd DialogBox \basetest\btsd.ini INTEROPUSB_INBOUND
RUN_TEST_STEP -1 basetestsd USB \basetest\btsd.ini
RUN_TEST_STEP 500 basetestsd ReadFiles1 \basetest\btsd.ini INTEROP_INBOUND
RUN_TEST_STEP 2000 basetestsd FileOperations2 \basetest\btsd.ini INTEROP_INBOUND
RUN_TEST_STEP 500 basetestsd ReadFiles2 \basetest\btsd.ini INTEROP_INBOUND
RUN_TEST_STEP 500 basetestsd CheckDisk \basetest\btsd.ini
END_TESTCASE PBASE-INTEROPUSBINBOUND-0212