os/kernelhwsrv/kerneltest/f32test/server/t_notify_mfs.cpp
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of the License "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // f32test\server\t_notify_mfs.cpp
    15 // 
    16 //
    17 
    18 #include "t_notify_perf.h"
    19 
    20 RTest test(_L("T_NOTIFY_MFS - Multi File Session Test For Enhanced Notification"));
    21 
    22 extern void ClearTestPathL();
    23 extern void SetTestPaths();
    24 extern void CopyLogFilesL();
    25 extern void DeleteLogFilesL();
    26 
    27 //---------------------------------------------
    28 //! @SYMTestCaseID          PBASE-T_NOTIFY-2457
    29 //! @SYMTestType            PT/UT
    30 //! @SYMREQ                 PREQ1847
    31 //! @SYMTestCaseDesc        Performance Test – Multiple File Server Sessions, this is only a part of the test case.
    32 //!                         It is executed as a functional test here. This test case is also run as performance test in t_notify_perf 
    33 //! @SYMTestActions         Perform a series of file operations, create multiple notification threads to collect the notifications.                        
    34 //! @SYMTestExpectedResults No notifications are missed
    35 //! @SYMTestPriority        High
    36 //! @SYMTestStatus          Implemented
    37 //---------------------------------------------
    38 LOCAL_C void MultipleFileSessionTestL()
    39     {
    40     test.Start(_L("T_NOTIFY_MFS - Test Preparation"));
    41     
    42     gPerfMeasure = EFalse;
    43     SetTestPaths();
    44     DeleteLogFilesL();  // Does not write log file but need create the log folder for test stopper to use
    45     
    46     const TInt KNumFiles = 10;
    47     const TInt KNumClients = 4;
    48     
    49     test.Next(_L("Single Notification on all clients"));
    50     ClearTestPathL();
    51     TTestSetting setting (KNumFiles, KNumClients, (EEnhanced|EBigBuffer), KDefaultOpList);
    52     CTestExecutor testcase (setting);
    53     testcase.RunTestCaseL();
    54     
    55     test.Next(_L("Multi notifications Mode 1, enhanced notification"));
    56     ClearTestPathL();
    57     setting.iOption = (EEnhanced|EBigBuffer|EMultiNoti1);
    58     testcase.SetTestSetting(setting);
    59     testcase.RunTestCaseL();
    60     
    61     test.Next(_L("Multi notifications Mode 2, enhanced notification"));
    62     ClearTestPathL();
    63     setting.iOption = (EEnhanced|EBigBuffer|EMultiNoti2);
    64     testcase.SetTestSetting(setting);
    65     testcase.RunTestCaseL();
    66     
    67     test.Next(_L("Test finishing - clearing test path"));
    68     
    69     ClearTestPathL();
    70     test.End();
    71     }
    72 
    73 // Entry Point
    74 GLDEF_C void CallTestsL()
    75     {
    76     MultipleFileSessionTestL();
    77     }
    78 
    79 
    80