aboutsummaryrefslogtreecommitdiff
path: root/test/expr.test
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2008-08-22 16:29:51 +0000
committerdrh <drh@noemail.net>2008-08-22 16:29:51 +0000
commit9d8b3072ce496b3aa80c094932ef455e6d0407d4 (patch)
tree594b9e71eb1f402e15c2a1600f71e235b21bfeb1 /test/expr.test
parenta858aa2e8caf7be20495f7e878e79951d6eebd07 (diff)
downloadsqlite-9d8b3072ce496b3aa80c094932ef455e6d0407d4.tar.gz
sqlite-9d8b3072ce496b3aa80c094932ef455e6d0407d4.zip
Enhanced test coverage. (CVS 5598)
FossilOrigin-Name: cc36b4e016a1f519ca81d591de3a551ee8aa6813
Diffstat (limited to 'test/expr.test')
-rw-r--r--test/expr.test16
1 files changed, 15 insertions, 1 deletions
diff --git a/test/expr.test b/test/expr.test
index 205af0d75..6cd46f924 100644
--- a/test/expr.test
+++ b/test/expr.test
@@ -11,7 +11,7 @@
# This file implements regression tests for SQLite library. The
# focus of this file is testing expressions.
#
-# $Id: expr.test,v 1.64 2008/07/30 13:27:11 drh Exp $
+# $Id: expr.test,v 1.65 2008/08/22 16:29:51 drh Exp $
set testdir [file dirname $argv0]
source $testdir/tester.tcl
@@ -607,6 +607,20 @@ test_expr2 expr-7.61 {GLOB('1?',a)} {10 11 12 13 14 15 16 17 18 19}
test_expr2 expr-7.62 {GLOB('1*4',b)} {10 14}
test_expr2 expr-7.63 {GLOB('*1[456]',b)} {4}
+breakpoint
+test_expr2 expr-7.64 {b = abs(-2)} {1}
+test_expr2 expr-7.65 {b = abs(+-2)} {1}
+test_expr2 expr-7.66 {b = abs(++-2)} {1}
+test_expr2 expr-7.67 {b = abs(+-+-2)} {1}
+test_expr2 expr-7.68 {b = abs(+-++-2)} {1}
+test_expr2 expr-7.69 {b = abs(++++-2)} {1}
+test_expr2 expr-7.70 {b = 5 - abs(+3)} {1}
+test_expr2 expr-7.71 {b = 5 - abs(-3)} {1}
+test_expr2 expr-7.72 {b = abs(-2.0)} {1}
+test_expr2 expr-7.73 {b = 6 - abs(-a)} {2}
+test_expr2 expr-7.74 {b = abs(8.0)} {3}
+
+
# Test the CURRENT_TIME, CURRENT_DATE, and CURRENT_TIMESTAMP expressions.
#
set sqlite_current_time 1157124849