Changeset: 34548b4902b9 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=34548b4902b9
Added Files:
        sql/test/testdb-upgrade-chain/Tests/All
        sql/test/testdb-upgrade-chain/Tests/dump.SQL.py
        sql/test/testdb-upgrade-chain/Tests/dump.reqtests
        sql/test/testdb-upgrade-chain/Tests/dump.stable.err
        sql/test/testdb-upgrade-chain/Tests/dump.stable.out
        sql/test/testdb-upgrade-chain/Tests/dump.timeout
        sql/test/testdb-upgrade-chain/Tests/package.py
        sql/test/testdb-upgrade-chain/Tests/package.reqtests
        sql/test/testdb-upgrade-chain/Tests/package.stable.err
        sql/test/testdb-upgrade-chain/Tests/package.stable.out
        sql/test/testdb-upgrade-chain/Tests/unpackage.py
        sql/test/testdb-upgrade-chain/Tests/unpackage.stable.err
        sql/test/testdb-upgrade-chain/Tests/unpackage.stable.out
        sql/test/testdb-upgrade-chain/Tests/upgrade.SQL.py
        sql/test/testdb-upgrade-chain/Tests/upgrade.reqtests
        sql/test/testdb-upgrade-chain/Tests/upgrade.stable.err
        sql/test/testdb-upgrade-chain/Tests/upgrade.stable.out
        sql/test/testdb-upgrade/Tests/All
        sql/test/testdb-upgrade/Tests/dump.SQL.py
        sql/test/testdb-upgrade/Tests/dump.reqtests
        sql/test/testdb-upgrade/Tests/dump.stable.err
        sql/test/testdb-upgrade/Tests/dump.stable.out
        sql/test/testdb-upgrade/Tests/dump.timeout
        sql/test/testdb-upgrade/Tests/unpackage.py
        sql/test/testdb-upgrade/Tests/unpackage.stable.err
        sql/test/testdb-upgrade/Tests/unpackage.stable.out
        sql/test/testdb-upgrade/Tests/upgrade.SQL.py
        sql/test/testdb-upgrade/Tests/upgrade.reqtests
        sql/test/testdb-upgrade/Tests/upgrade.stable.err
        sql/test/testdb-upgrade/Tests/upgrade.stable.out
        sql/test/testdb/Tests/testdb-package.py
        sql/test/testdb/Tests/testdb-package.reqtests
        sql/test/testdb/Tests/testdb-package.stable.err
        sql/test/testdb/Tests/testdb-package.stable.out
Modified Files:
        sql/test/testdb/Tests/All
        testing/Mtest.py.in
Branch: Jul2012
Log Message:

Implemented upgrade testing.
If Mtest.py is called with the --releaserun option, we set the
conditional RELEASERUN to true.  This makes that a "package" test is
run in the sql/test/testdb directory which packages the database in a
zip file called newrel.zip.  Also, if a zip file prevrel.zip and/or
prevchainrel.zip exist, we set the conditionals PREVREL / PREVCHAINREL
which causes tests in the sql/test/testdb-upgrade and
sql/test/testdb-upgrade-chain directories to run.  These tests unpack
the zip file, run an upgrade test (as a user other than monetdb) and
dump the database to check that the upgrade worked.  In case
--releaserun is set, the chain version creates a zip file from the
database after the upgrade.

This changeset also contains an extra feature in Mtest.py: you can now
have a conjunction of multiple conditionals in the "All" file.


diffs (truncated from 203280 to 300 lines):

diff --git a/sql/test/testdb-upgrade-chain/Tests/All 
b/sql/test/testdb-upgrade-chain/Tests/All
new file mode 100644
--- /dev/null
+++ b/sql/test/testdb-upgrade-chain/Tests/All
@@ -0,0 +1,4 @@
+PREVCHAINREL?unpackage
+PREVCHAINREL?upgrade
+PREVCHAINREL&RELEASERUN?package
+PREVCHAINREL?dump
diff --git a/sql/test/testdb-upgrade-chain/Tests/dump.SQL.py 
b/sql/test/testdb-upgrade-chain/Tests/dump.SQL.py
new file mode 100644
--- /dev/null
+++ b/sql/test/testdb-upgrade-chain/Tests/dump.SQL.py
@@ -0,0 +1,10 @@
+import sys
+try:
+    from MonetDBtesting import process
+except ImportError:
+    import process
+
+p = process.client('sqldump', stdout = process.PIPE, stderr = process.PIPE)
+out, err = p.communicate()
+sys.stdout.write(out)
+sys.stderr.write(err)
diff --git a/sql/test/testdb-upgrade-chain/Tests/dump.reqtests 
b/sql/test/testdb-upgrade-chain/Tests/dump.reqtests
new file mode 100644
--- /dev/null
+++ b/sql/test/testdb-upgrade-chain/Tests/dump.reqtests
@@ -0,0 +1,1 @@
+upgrade
diff --git a/sql/test/testdb-upgrade-chain/Tests/dump.stable.err 
b/sql/test/testdb-upgrade-chain/Tests/dump.stable.err
new file mode 100644
--- /dev/null
+++ b/sql/test/testdb-upgrade-chain/Tests/dump.stable.err
@@ -0,0 +1,37 @@
+stderr of test 'dump` in directory 'test/testdb-upgrade-chain` itself:
+
+
+# 15:37:18 >  
+# 15:37:18 >  "mserver5" "--debug=10" "--set" "gdk_nr_threads=0" "--set" 
"gdk_dbfarm=/ufs/sjoerd/Monet-stable/var/MonetDB" "--set" "mapi_open=true" 
"--set" "mapi_port=31490" "--set" "monet_prompt=" "--trace" "--forcemito" 
"--set" "mal_listing=2" "--dbname=mTests_test_testdb-upgrade-chain" "--set" 
"mal_listing=0"
+# 15:37:18 >  
+
+# builtin opt  gdk_dbname = demo
+# builtin opt  gdk_dbfarm = /ufs/sjoerd/Monet-stable/var/monetdb5/dbfarm
+# builtin opt  gdk_debug = 0
+# builtin opt  gdk_alloc_map = no
+# builtin opt  gdk_vmtrim = yes
+# builtin opt  monet_prompt = >
+# builtin opt  monet_daemon = no
+# builtin opt  mapi_port = 50000
+# builtin opt  mapi_open = false
+# builtin opt  mapi_autosense = false
+# builtin opt  sql_optimizer = default_pipe
+# builtin opt  sql_debug = 0
+# cmdline opt  gdk_nr_threads = 0
+# cmdline opt  gdk_dbfarm = /ufs/sjoerd/Monet-stable/var/MonetDB
+# cmdline opt  mapi_open = true
+# cmdline opt  mapi_port = 31490
+# cmdline opt  monet_prompt = 
+# cmdline opt  mal_listing = 2
+# cmdline opt  gdk_dbname = mTests_test_testdb-upgrade-chain
+# cmdline opt  mal_listing = 0
+
+# 15:37:18 >  
+# 15:37:18 >  "/usr/bin/python" "dump.SQL.py" "dump"
+# 15:37:18 >  
+
+
+# 15:39:24 >  
+# 15:39:24 >  "Done."
+# 15:39:24 >  
+
diff --git a/sql/test/testdb-upgrade-chain/Tests/dump.stable.out 
b/sql/test/testdb-upgrade-chain/Tests/dump.stable.out
new file mode 100644
--- /dev/null
+++ b/sql/test/testdb-upgrade-chain/Tests/dump.stable.out
@@ -0,0 +1,101266 @@
+stdout of test 'dump` in directory 'test/testdb-upgrade-chain` itself:
+
+
+# 15:37:18 >  
+# 15:37:18 >  "mserver5" "--debug=10" "--set" "gdk_nr_threads=0" "--set" 
"gdk_dbfarm=/ufs/sjoerd/Monet-stable/var/MonetDB" "--set" "mapi_open=true" 
"--set" "mapi_port=31490" "--set" "monet_prompt=" "--trace" "--forcemito" 
"--set" "mal_listing=2" "--dbname=mTests_test_testdb-upgrade-chain" "--set" 
"mal_listing=0"
+# 15:37:18 >  
+
+# MonetDB 5 server v11.11.8 (hg id: 34fcf4e7226d+)
+# This is an unreleased version
+# Serving database 'mTests_test_testdb-upgrade-chain', using 8 threads
+# Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically 
linked
+# Found 15.629 GiB available main-memory.
+# Copyright (c) 1993-July 2008 CWI.
+# Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved
+# Visit http://www.monetdb.org/ for further information
+# Listening for connection requests on mapi:monetdb://madrid.ins.cwi.nl:31490/
+# MonetDB/GIS module loaded
+# MonetDB/JAQL module loaded
+# MonetDB/SQL module loaded
+
+Ready.
+
+# 15:37:18 >  
+# 15:37:18 >  "/usr/bin/python" "dump.SQL.py" "dump"
+# 15:37:18 >  
+
+START TRANSACTION;
+CREATE USER "testuser" WITH ENCRYPTED PASSWORD 
'e9e633097ab9ceb3e48ec3f70ee2beba41d05d5420efee5da85f97d97005727587fda33ef4ff2322088f4c79e8133cc9cd9f3512f4d3a303cbdb5bc585415a00'
 NAME 'Test User' SCHEMA "sys";
+CREATE SCHEMA "testschema" AUTHORIZATION "testuser";
+ALTER USER "testuser" SET SCHEMA "testschema";
+CREATE SEQUENCE "testschema"."selfref_seq" AS INTEGER;
+CREATE SEQUENCE "testschema"."test_seq" AS INTEGER;
+SET SCHEMA "testschema";
+CREATE TABLE "testschema"."smallstring" (
+       "string1" VARCHAR(5),
+       "string2" CHAR(5),
+       "string3" CHARACTER LARGE OBJECT
+);
+COPY 66 RECORDS INTO "testschema"."smallstring" FROM stdin USING DELIMITERS 
'\t','\n','"';
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+"a0"   "b0"    "c0"
+"a1"   "b1"    "c1"
+"a2"   "b2"    "c2"
+"a3"   "b3"    "c3"
+"a4"   "b4"    "c4"
+"a5"   "b5"    "c5"
+"a6"   "b6"    "c6"
+"a7"   "b7"    "c7"
+"a8"   "b8"    "c8"
+"a9"   "b9"    "c9"
+"a10"  "b10"   "c10"
+CREATE TABLE "testschema"."mediumstring" (
+       "string1" VARCHAR(20),
+       "string2" CHAR(20),
+       "string3" CHARACTER LARGE OBJECT
+);
+COPY 1001 RECORDS INTO "testschema"."mediumstring" FROM stdin USING DELIMITERS 
'\t','\n','"';
+"a222833216428103"     "b222833216428103"      "c222833216428103"
+"a22462275706708"      "b22462275706708"       "c22462275706708"
+"a207961069219280"     "b207961069219280"      "c207961069219280"
+"a1430667456508"       "b1430667456508"        "c1430667456508"
+"a143912596726204"     "b143912596726204"      "c143912596726204"
+"a35882931026608"      "b35882931026608"       "c35882931026608"
+"a12630311241498"      "b12630311241498"       "c12630311241498"
+"a1147528919691"       "b1147528919691"        "c1147528919691"
+"a2463126399106"       "b2463126399106"        "c2463126399106"
+"a26499139713669"      "b26499139713669"       "c26499139713669"
+"a1248634873065"       "b1248634873065"        "c1248634873065"
+"a78212594930635"      "b78212594930635"       "c78212594930635"
+"a14529139788559"      "b14529139788559"       "c14529139788559"
+"a10412828415305"      "b10412828415305"       "c10412828415305"
+"a754999078504"        "b754999078504" "c754999078504"
+"a985134955047"        "b985134955047" "c985134955047"
+"a27593261253403"      "b27593261253403"       "c27593261253403"
+"a29091483332322"      "b29091483332322"       "c29091483332322"
+"a29783294642194"      "b29783294642194"       "c29783294642194"
+"a61212319516165"      "b61212319516165"       "c61212319516165"
+"a9790291319652"       "b9790291319652"        "c9790291319652"
+"a128551073512834"     "b128551073512834"      "c128551073512834"
+"a107222526426812"     "b107222526426812"      "c107222526426812"
+"a192822630622328"     "b192822630622328"      "c192822630622328"
+"a1819108732235"       "b1819108732235"        "c1819108732235"
+"a10323207312962"      "b10323207312962"       "c10323207312962"
+"a15370296666320"      "b15370296666320"       "c15370296666320"
+"a187742599011153"     "b187742599011153"      "c187742599011153"
+"a18328230057849"      "b18328230057849"       "c18328230057849"
+"a205222912631044"     "b205222912631044"      "c205222912631044"
+"a392061491190"        "b392061491190" "c392061491190"
+"a235721900411925"     "b235721900411925"      "c235721900411925"
+"a3638297274421"       "b3638297274421"        "c3638297274421"
+"a304501624130727"     "b304501624130727"      "c304501624130727"
+"a200101806031815"     "b200101806031815"      "c200101806031815"
+"a19477283831120"      "b19477283831120"       "c19477283831120"
+"a324401098630786"     "b324401098630786"      "c324401098630786"
+"a59922976024008"      "b59922976024008"       "c59922976024008"
+"a171451532014245"     "b171451532014245"      "c171451532014245"
+"a24994307510604"      "b24994307510604"       "c24994307510604"
+"a23270699516753"      "b23270699516753"       "c23270699516753"
+"a24460305672989"      "b24460305672989"       "c24460305672989"
+"a3617143832716"       "b3617143832716"        "c3617143832716"
+"a80393188816189"      "b80393188816189"       "c80393188816189"
+"a5998191311481"       "b5998191311481"        "c5998191311481"
+"a5045584029865"       "b5045584029865"        "c5045584029865"
+"a616555128083"        "b616555128083" "c616555128083"
+"a4184115045075"       "b4184115045075"        "c4184115045075"
+"a281922864920395"     "b281922864920395"      "c281922864920395"
+"a96702087523470"      "b96702087523470"       "c96702087523470"
+"a202741137830465"     "b202741137830465"      "c202741137830465"
+"a4259307028265"       "b4259307028265"        "c4259307028265"
+"a7248668829703"       "b7248668829703"        "c7248668829703"
+"a71971472728823"      "b71971472728823"       "c71971472728823"
+"a233862072515186"     "b233862072515186"      "c233862072515186"
+"a248682577121027"     "b248682577121027"      "c248682577121027"
+"a219653193626539"     "b219653193626539"      "c219653193626539"
+"a3004833525276"       "b3004833525276"        "c3004833525276"
+"a2355315451157"       "b2355315451157"        "c2355315451157"
+"a22750844722033"      "b22750844722033"       "c22750844722033"
+"a1345328721643"       "b1345328721643"        "c1345328721643"
+"a111502123713"        "b111502123713" "c111502123713"
+"a6647746010401"       "b6647746010401"        "c6647746010401"
+"a35821465725128"      "b35821465725128"       "c35821465725128"
+"a32406527613086"      "b32406527613086"       "c32406527613086"
+"a14824301446089"      "b14824301446089"       "c14824301446089"
+"a3083193415257"       "b3083193415257"        "c3083193415257"
+"a29623166218610"      "b29623166218610"       "c29623166218610"
+"a2131189767387"       "b2131189767387"        "c2131189767387"
+"a3288895815834"       "b3288895815834"        "c3288895815834"
+"a253212241111787"     "b253212241111787"      "c253212241111787"
+"a2596479411999"       "b2596479411999"        "c2596479411999"
+"a29678744119459"      "b29678744119459"       "c29678744119459"
+"a7311110241349"       "b7311110241349"        "c7311110241349"
+"a32440106626625"      "b32440106626625"       "c32440106626625"
+"a12758254864001"      "b12758254864001"       "c12758254864001"
+"a188472857023342"     "b188472857023342"      "c188472857023342"
+"a24104254257195"      "b24104254257195"       "c24104254257195"
+"a327142755626171"     "b327142755626171"      "c327142755626171"
+"a7333308442361"       "b7333308442361"        "c7333308442361"
+"a231672339824773"     "b231672339824773"      "c231672339824773"
+"a21861659425567"      "b21861659425567"       "c21861659425567"
+"a1418513504240"       "b1418513504240"        "c1418513504240"
+"a8772081611264"       "b8772081611264"        "c8772081611264"
+"a22262048821926"      "b22262048821926"       "c22262048821926"
+"a885147814645"        "b885147814645" "c885147814645"
+"a128521932510447"     "b128521932510447"      "c128521932510447"
+"a3426106613104"       "b3426106613104"        "c3426106613104"
+"a106211060830660"     "b106211060830660"      "c106211060830660"
+"a40241794128736"      "b40241794128736"       "c40241794128736"
+"a6385834119366"       "b6385834119366"        "c6385834119366"
+"a31158105273193"      "b31158105273193"       "c31158105273193"
+"a239572471316697"     "b239572471316697"      "c239572471316697"
+"a24198255904745"      "b24198255904745"       "c24198255904745"
+"a26942781625233"      "b26942781625233"       "c26942781625233"
+"a24621389925711"      "b24621389925711"       "c24621389925711"
+"a64981675112268"      "b64981675112268"       "c64981675112268"
+"a169452017722930"     "b169452017722930"      "c169452017722930"
+"a2004930798770"       "b2004930798770"        "c2004930798770"
+"a17941205418711"      "b17941205418711"       "c17941205418711"
+"a13909843927052"      "b13909843927052"       "c13909843927052"
+"a50868304812" "b50868304812"  "c50868304812"
+"a37013078729525"      "b37013078729525"       "c37013078729525"
+"a203982221722347"     "b203982221722347"      "c203982221722347"
+"a251442491217395"     "b251442491217395"      "c251442491217395"
+"a176091676521294"     "b176091676521294"      "c176091676521294"
+"a10553232635277"      "b10553232635277"       "c10553232635277"
+"a22821744025454"      "b22821744025454"       "c22821744025454"
+"a129832748923484"     "b129832748923484"      "c129832748923484"
+"a137531266225538"     "b137531266225538"      "c137531266225538"
+"a32465265711209"      "b32465265711209"       "c32465265711209"
+"a26749270798039"      "b26749270798039"       "c26749270798039"
_______________________________________________
Checkin-list mailing list
Checkin-list@monetdb.org
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to