diff options
author | jbj <devnull@localhost> | 2003-12-15 21:42:09 +0000 |
---|---|---|
committer | jbj <devnull@localhost> | 2003-12-15 21:42:09 +0000 |
commit | 8960e3895f7af91126465368dff8fbb36ab4e853 (patch) | |
tree | 3c515e39dde0e88edeb806ea87d08524ba25c761 /db/test/test064.tcl | |
parent | 752cac72e220dcad4e6fce39508e714e59e3e0a1 (diff) | |
download | rpm-8960e3895f7af91126465368dff8fbb36ab4e853.tar.gz rpm-8960e3895f7af91126465368dff8fbb36ab4e853.tar.bz2 rpm-8960e3895f7af91126465368dff8fbb36ab4e853.zip |
- upgrade to db-4.2.52.
CVS patchset: 6972
CVS date: 2003/12/15 21:42:09
Diffstat (limited to 'db/test/test064.tcl')
-rw-r--r-- | db/test/test064.tcl | 35 |
1 files changed, 21 insertions, 14 deletions
diff --git a/db/test/test064.tcl b/db/test/test064.tcl index ad39f4b22..496b80df6 100644 --- a/db/test/test064.tcl +++ b/db/test/test064.tcl @@ -1,46 +1,53 @@ # See the file LICENSE for redistribution information. # -# Copyright (c) 1999, 2000 +# Copyright (c) 1999-2003 # Sleepycat Software. All rights reserved. # -# $Id: test064.tcl,v 11.8 2000/08/25 14:21:58 sue Exp $ +# $Id: test064.tcl,v 11.15 2003/01/08 05:54:00 bostic Exp $ # -# DB Test 64: Test of DB->get_type -# Create a database of type specified by method. -# Make sure DB->get_type returns the right thing with both a -# normal and DB_UNKNOWN open. +# TEST test064 +# TEST Test of DB->get_type +# TEST Create a database of type specified by method. +# TEST Make sure DB->get_type returns the right thing with both a normal +# TEST and DB_UNKNOWN open. proc test064 { method args } { source ./include.tcl set args [convert_args $method $args] set omethod [convert_method $method] - set tnum 64 + set tnum "064" + set txnenv 0 set eindex [lsearch -exact $args "-env"] # # If we are using an env, then testfile should just be the db name. # Otherwise it is the test directory and the name. if { $eindex == -1 } { - set testfile $testdir/test0$tnum.db + set testfile $testdir/test$tnum.db set env NULL } else { - set testfile test0$tnum.db + set testfile test$tnum.db incr eindex set env [lindex $args $eindex] + set txnenv [is_txnenv $env] + if { $txnenv == 1 } { + append args " -auto_commit " + } + set testdir [get_home $env] } cleanup $testdir $env - puts "Test0$tnum: $method ($args) DB->get_type test." + puts "Test$tnum: $method ($args) DB->get_type test." # Create a test database. - puts "\tTest0$tnum.a: Creating test database of type $method." - set db [eval {berkdb_open -create -truncate -mode 0644} \ + puts "\tTest$tnum.a: Creating test database of type $method." + set db [eval {berkdb_open -create -mode 0644} \ $omethod $args $testfile] error_check_good db_create [is_valid_db $db] TRUE error_check_good db_close [$db close] 0 - puts "\tTest0$tnum.b: get_type after method specifier." + puts "\tTest$tnum.b: get_type after method specifier." set db [eval {berkdb_open} $omethod $args {$testfile}] error_check_good db_open [is_valid_db $db] TRUE @@ -50,7 +57,7 @@ proc test064 { method args } { error_check_good db_close [$db close] 0 - puts "\tTest0$tnum.c: get_type after DB_UNKNOWN." + puts "\tTest$tnum.c: get_type after DB_UNKNOWN." set db [eval {berkdb_open} $args $testfile] error_check_good db_open [is_valid_db $db] TRUE |