aboutsummaryrefslogtreecommitdiff
path: root/test/backup2.test
diff options
context:
space:
mode:
authordan <Dan Kennedy>2021-02-12 21:22:01 +0000
committerdan <Dan Kennedy>2021-02-12 21:22:01 +0000
commit8b7e93adbce69298fb80c69dbeae5db167f5d7a9 (patch)
treebb0871714ac8220ef380542f67ad0820ea13c541 /test/backup2.test
parent23ed8109b67b55db4b30ed7e82ede7e676582884 (diff)
downloadsqlite-8b7e93adbce69298fb80c69dbeae5db167f5d7a9.tar.gz
sqlite-8b7e93adbce69298fb80c69dbeae5db167f5d7a9.zip
Fix a test case to account for the fact that different versions of OpenBSD behave differently when a program tries to read() from a file-descriptor open on a directory.
FossilOrigin-Name: ecd712032f56a20d7df2bcf89b0d3b8d91dc72c552e27f0a4b23980bd49747b0
Diffstat (limited to 'test/backup2.test')
-rw-r--r--test/backup2.test5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/backup2.test b/test/backup2.test
index b58c6a3cd..8b9cb8731 100644
--- a/test/backup2.test
+++ b/test/backup2.test
@@ -144,7 +144,7 @@ do_test backup2-9 {
if {$tcl_platform(platform)=="windows"} {
set msg {cannot open source database: unable to open database file}
} elseif {[string match *BSD $tcl_platform(os)]} {
- set msg {restore failed: file is not a database}
+ set msg {}
} else {
set msg {cannot open source database: disk I/O error}
}
@@ -152,7 +152,8 @@ do_test backup2-10 {
forcedelete bu3.db
file mkdir bu3.db
set rc [catch {db restore temp bu3.db} res]
- lappend rc $res
+ if {0==[string match *BSD $tcl_platform(os)]} { lappend rc $res }
+ set rc
} [list 1 $msg]
# Try to restore from something that is not a database file.