vmbx/vmbxengine/tsrc/ut_vmbxengine/ut_vmbxengine.h
branchGCC_SURGE
changeset 34 8ed2e80af9dd
parent 26 c9c7ab911778
parent 32 1f002146abb4
equal deleted inserted replaced
26:c9c7ab911778 34:8ed2e80af9dd
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Implementation of the Ut_vmbxEngine class
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef _UT_VMBXENGINE_H
       
    19 #define _UT_VMBXENGINE_H
       
    20 
       
    21 #include <QtTest/QtTest>
       
    22 #include <QString>
       
    23 #include <QStringList>
       
    24 #include <QSignalSpy>
       
    25 #include <QMetaType>
       
    26 #include <QObject>
       
    27 
       
    28 
       
    29 // Class forwards
       
    30 class CVoiceMailbox;
       
    31 class CVmbxUiHandler;
       
    32 class VmbxQtUiHandler;
       
    33 class HbMainWindow;
       
    34 
       
    35 
       
    36 /**
       
    37  *  Ut_vmbxEngine unit test class.
       
    38  * 
       
    39  *  Tests vmbxEngine cpp files public APIS.
       
    40  *  See cpp file for more information. 
       
    41  *
       
    42  *  @lib ut_vmbxengine.lib
       
    43  *  @since S60 <TB10.1>
       
    44  */
       
    45 class Ut_vmbxEngine : public QObject
       
    46 {
       
    47     Q_OBJECT
       
    48 
       
    49 public:
       
    50     Ut_vmbxEngine();
       
    51     virtual ~Ut_vmbxEngine();
       
    52 
       
    53     //void testResult(const bool aResult);
       
    54 
       
    55 private slots: 
       
    56 
       
    57      /**
       
    58      * Called before the first testfunction is executed.
       
    59      * Handles the SetUpMenu command.
       
    60      */
       
    61     void initTestCase();
       
    62 
       
    63      /**
       
    64      * Called after the last testfunction has been executed.
       
    65      * 
       
    66      */
       
    67     void cleanupTestCase();
       
    68     
       
    69     /**
       
    70     * Test middle case,CreateWindow
       
    71     * 
       
    72     * provide window for UI
       
    73     */
       
    74     void testCreateWindow();
       
    75 
       
    76     /**
       
    77     * Test middle case,showVmbxQueryDialog
       
    78     * 
       
    79     */   
       
    80     void testshowVmbxQueryDialog();
       
    81 
       
    82      /**
       
    83      * Test middle case,showDefineSelectionDialog
       
    84      * 
       
    85      */
       
    86     void testshowDefineSelectionDialog();
       
    87 
       
    88      /**
       
    89      * Test first case,Create CVoiceMailbox
       
    90      * 
       
    91      */
       
    92     void testCreateVmbxMailbox();
       
    93 
       
    94     void testshowSaveEmptyNote_data();
       
    95 
       
    96      /**
       
    97      * Test middle case,showSaveEmptyNote
       
    98      * 
       
    99      */
       
   100     void testshowSaveEmptyNote();
       
   101 
       
   102     /**
       
   103     * Test middle case,delete HbMainWindow
       
   104     * 
       
   105     */  
       
   106     void testDeleteWindow();
       
   107       /**
       
   108      * Test last case,delete CVoiceMailbox
       
   109      * 
       
   110      */
       
   111     void testDeleteVmbxMailbox();
       
   112 
       
   113 private:  //data
       
   114 
       
   115     /**
       
   116      * Own.
       
   117      */
       
   118     CVoiceMailbox* mVmbxEngine;
       
   119 
       
   120     /**
       
   121      * Own.
       
   122      */
       
   123     CVmbxUiHandler *mUiHandler;
       
   124   
       
   125     /**
       
   126      * Own.
       
   127      */
       
   128     VmbxQtUiHandler *mQtUiHandler;
       
   129     
       
   130     /**
       
   131      * Own.
       
   132      */
       
   133     HbMainWindow* mWindow;
       
   134 };
       
   135 
       
   136 #endif // _UT_VMBXENGINE_H