Changeset: 80f775223097 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=80f775223097 Added Files: sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.py Removed Files: sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.sql sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.err.int128 sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.out.int128 Branch: mtest Log Message:
Unified 128 and no int128 outputs for bit_and.SF-2850341 test diffs (166 lines): diff --git a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.sql b/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.py rename from sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.sql rename to sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.py --- a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.sql +++ b/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.py @@ -1,3 +1,23 @@ -select bit_and(3749090034127126942, -1); -select bit_and(3749090034127126942, 0x7fffffffffffffff); -select bit_and(3749090034127126942, 0xffffffffffffffff); +import sys, os, pymonetdb + +db = os.getenv("TSTDB") +port = int(os.getenv("MAPIPORT")) + +conn1 = pymonetdb.connect(database=db, port=port, autocommit=True, username='monetdb', password='monetdb') +cur1 = conn1.cursor() +try: + cur1.execute('select cast(1 as hugeint)') + has_huge = True +except pymonetdb.DatabaseError as e: + has_huge = False + +cur1.execute('select bit_and(3749090034127126942, -1);') +if cur1.fetchall() != [(3749090034127126942,)]: + sys.stderr.write('[(3749090034127126942,)] expected') +cur1.execute('select bit_and(3749090034127126942, 0x7fffffffffffffff);') +if cur1.fetchall() != [(3749090034127126942,)]: + sys.stderr.write('[(3749090034127126942,)] expected') +if has_huge: + cur1.execute('select bit_and(3749090034127126942, 0xffffffffffffffff);') + if cur1.fetchall() != [(3749090034127126942,)]: + sys.stderr.write('[(3749090034127126942,)] expected') diff --git a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.err.int128 b/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.err.int128 deleted file mode 100644 --- a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.err.int128 +++ /dev/null @@ -1,74 +0,0 @@ -stderr of test 'bit_and.SF-2850341` in directory 'sql/test/BugTracker-2009` itself: - - -# 22:31:14 > -# 22:31:14 > mserver5 "--config=/ufs/niels/scratch/rc/Linux-x86_64/etc/monetdb5.conf" --debug=10 --set gdk_nr_threads=0 --set "monet_mod_path=/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/lib:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/bin" --set "gdk_dbfarm=/ufs/niels/scratch/rc/Linux-x86_64/var/MonetDB5/dbfarm" --set mapi_open=true --set xrpc_open=true --set mapi_port=36767 --set xrpc_port=40172 --set monet_prompt= --trace "--dbname=mTests_src_test_BugTracker-2009" --set mal_listing=0 "--dbinit= include sql;" ; echo ; echo Over.. -# 22:31:14 > - -# builtin opt gdk_arch = 64bitx86_64-unknown-linux-gnu -# builtin opt gdk_version = 1.32.0 -# builtin opt prefix = /ufs/niels/scratch/rc/Linux-x86_64 -# builtin opt exec_prefix = ${prefix} -# builtin opt gdk_dbname = tst -# builtin opt gdk_dbfarm = ${prefix}/var/MonetDB -# builtin opt gdk_debug = 8 -# builtin opt gdk_alloc_map = yes -# builtin opt gdk_vmtrim = yes -# builtin opt monet_admin = adm -# builtin opt monet_prompt = > -# builtin opt monet_welcome = yes -# builtin opt monet_mod_path = ${exec_prefix}/lib/MonetDB -# builtin opt monet_daemon = yes -# builtin opt host = localhost -# builtin opt mapi_port = 50000 -# builtin opt mapi_noheaders = no -# builtin opt mapi_debug = 0 -# builtin opt mapi_clients = 2 -# builtin opt sql_debug = 0 -# builtin opt standoff_ns = http://monetdb.cwi.nl/standoff -# builtin opt standoff_start = start -# builtin opt standoff_end = end -# config opt prefix = /ufs/niels/scratch/rc/Linux-x86_64 -# config opt config = ${prefix}/etc/monetdb5.conf -# config opt prefix = /ufs/niels/scratch/rc/Linux-x86_64 -# config opt exec_prefix = ${prefix} -# config opt gdk_dbfarm = ${prefix}/var/MonetDB5/dbfarm -# config opt gdk_dbname = demo -# config opt gdk_alloc_map = no -# config opt gdk_embedded = no -# config opt gdk_debug = 0 -# config opt monet_mod_path = ${exec_prefix}/lib/MonetDB5:${exec_prefix}/lib/MonetDB5/lib:${exec_prefix}/lib/MonetDB5/bin -# config opt monet_daemon = no -# config opt monet_welcome = yes -# config opt mero_msglog = ${prefix}/var/log/MonetDB/merovingian.log -# config opt mero_errlog = ${prefix}/var/log/MonetDB/merovingian.log -# config opt mero_pidfile = ${prefix}/var/run/MonetDB/merovingian.pid -# config opt mal_init = ${exec_prefix}/lib/MonetDB5/mal_init.mal -# config opt mal_listing = 2 -# config opt mapi_port = 50000 -# config opt mapi_autosense = false -# config opt mapi_open = false -# config opt sql_optimizer = inline,remap,evaluate,costModel,coercions,emptySet,aliases,mergetable,deadcode,constants,commonTerms,joinPath,deadcode,reduce,garbageCollector,dataflow,history,multiplex -# cmdline opt config = /ufs/niels/scratch/rc/Linux-x86_64/etc/monetdb5.conf -# cmdline opt gdk_nr_threads = 0 -# cmdline opt monet_mod_path = /ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/lib:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/bin -# cmdline opt gdk_dbfarm = /ufs/niels/scratch/rc/Linux-x86_64/var/MonetDB5/dbfarm -# cmdline opt mapi_open = true -# cmdline opt xrpc_open = true -# cmdline opt mapi_port = 36767 -# cmdline opt xrpc_port = 40172 -# cmdline opt monet_prompt = -# cmdline opt gdk_dbname = mTests_src_test_BugTracker-2009 -# cmdline opt mal_listing = 0 -#warning: please don't forget to set your vault key! -#(see /ufs/niels/scratch/rc/Linux-x86_64/etc/monetdb5.conf) - -# 22:31:14 > -# 22:31:14 > mclient -lsql -umonetdb -Pmonetdb --host=alf --port=36767 -# 22:31:14 > - - -# 22:31:14 > -# 22:31:14 > Done. -# 22:31:14 > - diff --git a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.out.int128 b/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.out.int128 deleted file mode 100644 --- a/sql/test/BugTracker-2009/Tests/bit_and.SF-2850341.stable.out.int128 +++ /dev/null @@ -1,50 +0,0 @@ -stdout of test 'bit_and.SF-2850341` in directory 'sql/test/BugTracker-2009` itself: - - -# 22:31:14 > -# 22:31:14 > mserver5 "--config=/ufs/niels/scratch/rc/Linux-x86_64/etc/monetdb5.conf" --debug=10 --set gdk_nr_threads=0 --set "monet_mod_path=/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/lib:/ufs/niels/scratch/rc/Linux-x86_64/lib/MonetDB5/bin" --set "gdk_dbfarm=/ufs/niels/scratch/rc/Linux-x86_64/var/MonetDB5/dbfarm" --set mapi_open=true --set xrpc_open=true --set mapi_port=36767 --set xrpc_port=40172 --set monet_prompt= --trace "--dbname=mTests_src_test_BugTracker-2009" --set mal_listing=0 "--dbinit= include sql;" ; echo ; echo Over.. -# 22:31:14 > - -# MonetDB server v5.14.0, based on kernel v1.32.0 -# Serving database 'mTests_src_test_BugTracker-2009', using 4 threads -# Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked -# Copyright (c) 1993-July 2008 CWI. -# Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved -# Visit http://monetdb.cwi.nl/ for further information -# Listening for connection requests on mapi:monetdb://alf.ins.cwi.nl:36767/ -# MonetDB/SQL module v2.32.0 loaded - -#function user.main():void; -# clients.quit(); -#end main; - - -# 22:31:14 > -# 22:31:14 > mclient -lsql -umonetdb -Pmonetdb --host=alf --port=36767 -# 22:31:14 > - -#select bit_and(3749090034127126942, -1); -% .%2 # table_name -% %2 # name -% bigint # type -% 19 # length -[ 3749090034127126942 ] - -#select bit_and(3749090034127126942, 0x7fffffffffffffff); -% .%2 # table_name -% %2 # name -% bigint # type -% 19 # length -[ 3749090034127126942 ] - -#select bit_and(3749090034127126942, 0xffffffffffffffff); -% .%2 # table_name -% %2 # name -% hugeint # type -% 19 # length -[ 3749090034127126942 ] - -# 18:18:45 > -# 18:18:45 > "Done." -# 18:18:45 > - _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list