summaryrefslogtreecommitdiff
path: root/test/resolver01.test
diff options
context:
space:
mode:
authorHans-Christoph Steiner <hans@eds.org>2013-08-13 15:43:01 -0400
committerHans-Christoph Steiner <hans@eds.org>2013-08-13 15:43:01 -0400
commit4228998fd796fa2f9e84fb73632e0a07cc7cd188 (patch)
tree15b2336f351468fedd0c39e9de4ad905a686f3b0 /test/resolver01.test
parentbdee7cf7d974b2f70d5934786c5666006e7360be (diff)
parent08119c361d1181b3e8f1abb429236e488a664753 (diff)
Merge tag 'upstream/2.2.1'
Upstream version 2.2.1 # gpg: Signature made Tue 13 Aug 2013 03:42:56 PM EDT using RSA key ID 374BBE81 # gpg: Good signature from "Hans-Christoph Steiner <hans@at.or.at>" # gpg: aka "[jpeg image of size 5408]" # gpg: aka "Hans-Christoph Steiner <hs420@nyu.edu>" # gpg: aka "Hans-Christoph Steiner <hans@eds.org>" # gpg: aka "Hans-Christoph Steiner <hans@guardianproject.info>" # gpg: aka "Hans-Christoph Steiner <hansi@nyu.edu>" # gpg: aka "Hans-Christoph Steiner <hans@guardianproject.info>"
Diffstat (limited to 'test/resolver01.test')
-rw-r--r--test/resolver01.test39
1 files changed, 39 insertions, 0 deletions
diff --git a/test/resolver01.test b/test/resolver01.test
new file mode 100644
index 0000000..3ca6ace
--- /dev/null
+++ b/test/resolver01.test
@@ -0,0 +1,39 @@
+# 2013-04-13
+#
+# 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 tests features of the name resolver (the component that
+# figures out what identifiers in the SQL statement refer to) that
+# were fixed by ticket [2500cdb9be]
+#
+
+set testdir [file dirname $argv0]
+source $testdir/tester.tcl
+
+do_test resolver01-1.1 {
+ catchsql {
+ CREATE TABLE t1(x, y); INSERT INTO t1 VALUES(11,22);
+ CREATE TABLE t2(y, z); INSERT INTO t2 VALUES(33,44);
+ SELECT 1 AS y FROM t1, t2 ORDER BY y;
+ }
+} {0 1}
+do_test resolver01-1.2 {
+ catchsql {
+ SELECT 2 AS y FROM t1, t2 ORDER BY y COLLATE nocase;
+ }
+} {0 2}
+do_test resolver01-1.3 {
+ catchsql {
+ SELECT 3 AS y FROM t1, t2 ORDER BY +y;
+ }
+} {0 3}
+
+
+finish_test