os/persistentdata/persistentstorage/sql/TEST/testexecute/SQLite/scripts/Panics.script
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 // Copyright (c) 2006-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 "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 // @file
    15 // 
    16 //
    17 
    18 //! @SYMTestSuiteName PDS-TEF-SQL-SUITE
    19 //! @SYMScriptTestEnvironment TEF
    20 //! @internalComponent
    21 //! @test
    22 
    23 PRINT Run SQL Tests
    24 
    25 LOAD_SUITE te_SQL_Suite
    26 
    27 START_TESTCASE SYSLIB-SQL-CIT-1800
    28 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1800
    29 //! @SYMTestCaseDesc  Attempt to use an RSqlStatement without an RSqlDatabase.
    30 //! @SYMTestPriority  High
    31 //! @SYMTestActions   See description and the config file.
    32 //! @SYMTestExpectedResults
    33 //!                  The test looks for specific panic codes generated
    34 //!                  when the equivalent of programmer errors are executed
    35 //!                  on the SQLite system. For example, attempting to use
    36 //!                  an RSqlStatement object without an open RSqlDatabase.
    37 //! @SYMREQ           REQ5792
    38 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-a
    39 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-b
    40 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-c
    41 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-d
    42 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-e
    43 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-f
    44 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-g
    45 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-h
    46 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-i
    47 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini One-j
    48 END_TESTCASE SYSLIB-SQL-CIT-1800
    49 
    50 START_TESTCASE SYSLIB-SQL-CIT-1801
    51 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1801
    52 //! @SYMTestCaseDesc  Attempt to use an RSqlDatabase that isn't open. First 
    53 //!                  opens a valid database, immediately closes it and then
    54 //!                  attempts to use an RSqlDatabase method.
    55 //! @SYMTestPriority  High
    56 //! @SYMTestActions   See description and the config file.
    57 //! @SYMTestExpectedResults
    58 //!                  Panics when an Exec or other RSqlDatabase method is
    59 //!                  attempted.
    60 //! @SYMREQ           REQ5792
    61 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two
    62 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-b
    63 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-c
    64 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-d
    65 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-e
    66 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-f
    67 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Two-g
    68 END_TESTCASE SYSLIB-SQL-CIT-1801
    69 
    70 START_TESTCASE SYSLIB-SQL-CIT-1802
    71 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1802
    72 //! @SYMTestCaseDesc  Attempt to use Column* calls following a failed Next.
    73 //! @SYMTestPriority  High
    74 //! @SYMTestActions   See description and the config file.
    75 //! @SYMTestExpectedResults
    76 //!                  The test looks for specific panic codes generated
    77 //!                  when Column* methods are called after Next returns
    78 //!                  'KSqlAtEnd'.
    79 //! @SYMREQ           REQ5792
    80 	RUN_PANIC_STEP_RESULT 130 USER 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three
    81 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-b
    82 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-c
    83 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-d
    84 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-e
    85 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-f
    86 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-g
    87 	RUN_PANIC_STEP_RESULT 11 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-h
    88 	RUN_PANIC_STEP_RESULT 5 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Three-i
    89 END_TESTCASE SYSLIB-SQL-CIT-1802
    90 
    91 START_TESTCASE SYSLIB-SQL-CIT-1803
    92 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1803
    93 //! @SYMTestCaseDesc  Use parameter and column indices which are out of bounds.
    94 //! @SYMTestPriority  High
    95 //! @SYMTestActions   See description and the config file.
    96 //! @SYMTestExpectedResults
    97 //!                  This test looks for specific panic codes generated
    98 //!                  when Bind and Column methods are called with Parameter
    99 //!                  and Column indices which are out of bounds.
   100 //! @SYMREQ           REQ5792
   101 	RUN_PANIC_STEP_RESULT 5 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Four
   102 	RUN_PANIC_STEP_RESULT 5 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Four-b
   103 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Four-c
   104 END_TESTCASE SYSLIB-SQL-CIT-1803
   105 
   106 START_TESTCASE SYSLIB-SQL-CIT-1804
   107 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1804
   108 //! @SYMTestCaseDesc  Attempt to read a cell in a table without selecting the
   109 //!                  column.
   110 //! @SYMTestPriority  High
   111 //! @SYMTestActions   See description and the config file.
   112 //! @SYMTestExpectedResults
   113 //!                  The test looks for a specific panic code generated
   114 //!                  when a Column* method is called on a column that hasn't
   115 //!                  been selected.
   116 //! @SYMREQ           REQ5792
   117 	RUN_PANIC_STEP_RESULT 130 USER 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Five
   118 END_TESTCASE SYSLIB-SQL-CIT-1804
   119 
   120 START_TESTCASE SYSLIB-SQL-CIT-1805
   121 //! @SYMTestCaseID    SYSLIB-SQL-CIT-1805
   122 //! @SYMTestCaseDesc  Attempt to write, using Bind to a non-existent table.
   123 //! @SYMTestPriority  High
   124 //! @SYMTestActions   See description and the config file.
   125 //! @SYMTestExpectedResults
   126 //!                  The test looks for a specific panic code generated
   127 //!                  when a Parameter Index call is made following a
   128 //!                  prepare on a non-existent table.
   129 //! @SYMREQ           REQ5792
   130 	RUN_PANIC_STEP_RESULT 2 SqlDb 100 te_SQL_Suite CSQLDDT z:\TEF_SQL\Panics.ini Six
   131 END_TESTCASE SYSLIB-SQL-CIT-1805
   132 
   133 RUN_UTILS DeleteFile C:\Panics0.db
   134