Artifact fc6f70ae3d94a141fc183c94680c488ecd3bd13b:

  • File test/num2.test — part of check-in [b55b217f6a] at 2013-05-28 20:33:15 on branch sqlite4-num — Further progress on decimal arithmetic. (user: dan size: 1076) [more...]

# 2013 May 29
#
# The author disclaims copyright to this source code.  In place of
# a legal notice, here is a blessing:
#
#    May you do good and not evil.
#    May you find forgiveness for yourself and forgive others.
#    May you share freely, never taking more than you give.
#
#***********************************************************************
# This file implements regression tests for SQLite library.  
#

set testdir [file dirname $argv0]
source $testdir/tester.tcl
set ::testprefix num2

do_execsql_test 1.1 { SELECT 1.0 }                     {1.0}
do_execsql_test 1.2 { SELECT typeof(1.0) }             {real}
do_execsql_test 1.3 { SELECT cast(1.0 AS TEXT) }       {1.0}
do_execsql_test 1.4 { SELECT cast((1.0+1.0) AS TEXT) } {2.0}

do_execsql_test 1.5 { SELECT typeof(1.0+1.0) }         {real}
do_execsql_test 1.6 { SELECT typeof(1.0*1.0) }         {real}
do_execsql_test 1.7 { SELECT typeof(1.0/1.0) }         {real}
do_execsql_test 1.8 { SELECT typeof(1.0-1.0) }         {real}
do_execsql_test 1.8 { SELECT typeof(1.0%1.0) }         {real}

finish_test