diff --git a/manifest b/manifest index 7b0d218ffc..4999390916 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Updates\sand\sminor\stypo\sfix\sfor\sthe\sREADME. -D 2018-01-13T02:07:16.057 +C Fix\svarious\sproblems\sin\stest\sscripts\spreventing\s"make\stest"\sfrom\spassing\son\nF2FS\sfile-systems\swith\sthe\s"atomic-write"\sfeature. +D 2018-01-13T13:07:49.167 F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1 F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea F Makefile.in 38f84f301cbef443b2d269f67a74b8cc536469831f70df7c3e912acc04932cc2 @@ -724,7 +724,7 @@ F test/crash4.test fe2821baf37168dc59dd733dcf7dba2a401487bc F test/crash5.test 05dd3aa9dbb751a22d5cdaf22a9c49b6667aa219 F test/crash6.test 4c56f1e40d0291e1110790a99807aa875b1647ba F test/crash7.test 1a194c4900a255258cf94b7fcbfd29536db572df -F test/crash8.test a63907617d8e74fb54b4bff23eca8a4435625245 +F test/crash8.test 64e464f22883be5184535a9620eb9070027073610d997bd2784227ca9564fb84 F test/crashM.test d95f59046fa749b0d0822edf18a717788c8f318d F test/crashtest1.c 09c1c7d728ccf4feb9e481671e29dda5669bbcc2 F test/createtab.test b5de160630b209c4b8925bdcbbaf48cc90b67fe8 @@ -744,7 +744,7 @@ F test/delete.test acc38fca8ee4851467705b1c2cfea64cd26667e5 F test/delete2.test 3a03f2cca1f9a67ec469915cb8babd6485db43fa F test/delete3.test 555e84a00a99230b7d049d477a324a631126a6ab F test/delete4.test 21d2113217eeaacac2d99defe14fe6611615ae86 -F test/delete_db.test c70a43629dd4d3e1dd03fdaf7a22153af6a69d92 +F test/delete_db.test 096d828493c7907f9ea11a7098ea6a0f73edba89406487d5d6cc2228dc4ab8b0 F test/descidx1.test 6d03b44c8538fe0eb4924e19fba10cdd8f3c9240 F test/descidx2.test 9f1a0c83fd57f8667c82310ca21b30a350888b5d F test/descidx3.test 09ddbe3f5295f482d2f8b687cf6db8bad7acd9a2 @@ -785,14 +785,14 @@ F test/enc4.test c8f1ce3618508fd0909945beb8b8831feef2c020 F test/eqp.test 3fe051af50921284189d1970eb653f9fcf5117d2 F test/errmsg.test eae9f091eb39ce7e20305de45d8e5d115b68fa856fba4ea6757b6ca3705ff7f9 F test/eval.test a64c9105d6ff163df7cf09d6ac29cdad5922078c -F test/exclusive.test 9a57bd66e39144b888ca75c309914fcdefb4e3f9 +F test/exclusive.test 1206b87e192497d78c7f35552e86a9d05421498da300fb1cce5ca5351ccde3c3 F test/exclusive2.test 984090e8e9d1b331d2e8111daf6e5d61dda0bef7 F test/exec.test e949714dc127eaa5ecc7d723efec1ec27118fdd7 F test/exists.test 79a75323c78f02bbe9c251ea502a092f9ef63dac F test/expr.test 66a2c9ac34f74f036faa4092f5402c7d3162fc93 F test/extension01.test 00d13cec817f331a687a243e0e5a2d87b0e358c9 F test/extraquick.test cb254400bd42bfb777ff675356aabf3287978f79 -F test/fallocate.test 87b5e43c872b7e69cd80b7b8813eb102b571a75d45dda24e38b65537bcc85733 +F test/fallocate.test 07416bd593a116d5893cb244f45a94d5c6fe030561df3bd972e6135f8106e509 F test/filectrl.test 6e871c2d35dead1d9a88e176e8d2ca094fec6bb3 F test/filefmt.test f393e80c4b8d493b7a7f8f3809a8425bbf4292af1f5140f01cb1427798a2bbd4 F test/fkey1.test d11dbb8a93ead9b5c46ae5d02da016d61245d47662fb2d844c99214f6163f768 @@ -1004,11 +1004,11 @@ F test/join3.test 6f0c774ff1ba0489e6c88a3e77b9d3528fb4fda0 F test/join4.test 1a352e4e267114444c29266ce79e941af5885916 F test/join5.test bc98ea4b4e5003f5b1453701ebb8cd7d1c01a550 F test/join6.test cfe6503791ceb0cbb509966740286ec423cbf10b -F test/journal1.test 69abc726c51b4a0409189f9a85191205297c0577 +F test/journal1.test c7b768041b7f494471531e17abc2f4f5ebf9e5096984f43ed17c4eb80ba34497 F test/journal2.test 9dac6b4ba0ca79c3b21446bbae993a462c2397c4 -F test/journal3.test ff8af941f9e06161d3db1b46bb9f965ff0e7f307 -F test/jrnlmode.test 7864d59cf7f6e552b9b99ba0f38acd167edc10fa -F test/jrnlmode2.test 81610545a4e6ed239ea8fa661891893385e23a1d +F test/journal3.test c9c29883f5bf535ae82ae21c472df6263806a22e467b6db7cd0d6d545305b4f6 +F test/jrnlmode.test a6693f2bed4541a21e703aaa37bb3e10de154130645952933b82b2dec0a8b539 +F test/jrnlmode2.test 8759a1d4657c064637f8b079592651530db738419e1d649c6df7048cd724363d F test/jrnlmode3.test 556b447a05be0e0963f4311e95ab1632b11c9eaa F test/json101.test d7cdf3e6731d41e0c4bde1c88806abd17f1f478486a1409933c1d8eac9120095 F test/json102.test eeb54efa221e50b74a2d6fb9259963b48d7414dca3ce2fdfdeed45cb28487bc1 @@ -1028,7 +1028,7 @@ F test/loadext2.test 0408380b57adca04004247179837a18e866a74f7 F test/lock.test be4fe08118fb988fed741f429b7dd5d65e1c90db F test/lock2.test 5242d8ac4e2d59c403aebff606af449b455aceff F test/lock3.test f271375930711ae044080f4fe6d6eda930870d00 -F test/lock4.test e175ae13865bc87680607563bafba21f31a26f12 +F test/lock4.test 27143363eda1622f03c133efc8db808fc331afd973486cb571ea71cd717d37b8 F test/lock5.test c6c5e0ebcb21c61a572870cc86c0cb9f14cede38 F test/lock6.test ad5b387a3a8096afd3c68a55b9535056431b0cf5 F test/lock7.test 49f1eaff1cdc491cc5dee3669f3c671d9f172431 @@ -1116,9 +1116,9 @@ F test/oserror.test b32dc34f2363ef18532e3a0a7358e3e7e321974f F test/ossfuzz.c 7f5cc87a0280a5854c1bfa7d5c4d07d34731f08ec34dc9c916aa35ed292b1468 F test/ossshell.c 296ab63067841bd1b1e97b46a0b2af48ee7f69d50d1a723008bee12dd7122622 F test/ovfl.test 199c482696defceacee8c8e0e0ef36da62726b2f -F test/pager1.test 8149b2a8986fee667ab6a8171ab310be19e77ae215bebad0e90c857b0df1935c +F test/pager1.test f596d3bd53ce96e1d87d44d223d2ae6c8867dd782c425e5eb28b5721fa6aaa97 F test/pager2.test 67b8f40ae98112bcdba1f2b2d03ea83266418c71 -F test/pager3.test 3856d9c80839be0668efee1b74811b1b7f7fc95f +F test/pager3.test 4e9a83d6ca0838d7c602c9eb93d1357562d9059c1e02ffb138a8271020838370 F test/pager4.test a122e9e6925d5b23b31e3dfef8c6a44bbf19590e F test/pagerfault.test 263c5442c06caf0b9b9e3fe42acdeb11f254dcebe533f69f401aaef9111eaf20 F test/pagerfault2.test caf4c7facb914fd3b03a17b31ae2b180c8d6ca1f @@ -1156,7 +1156,7 @@ F test/regexp2.test 40e894223b3d6672655481493f1be12012f2b33c F test/reindex.test 44edd3966b474468b823d481eafef0c305022254 F test/releasetest.tcl 6aaa853f7a7bbdc458d4cb42c0425228729b0f3e5769e9b41088c08eee999a49 x F test/resolver01.test f4022acafda7f4d40eca94dbf16bc5fc4ac30ceb -F test/rollback.test f580934279800d480a19176c6b44909df31ce7ad45267ea475a541daa522f3d3 +F test/rollback.test 06680159bc6746d0f26276e339e3ae2f951c64812468308838e0a3362d911eaa F test/rollback2.test 8435d6ff0f13f51d2a4181c232e706005fa90fc5 F test/rollbackfault.test 0e646aeab8840c399cfbfa43daab46fd609cf04a F test/rowallock.test 3f88ec6819489d0b2341c7a7528ae17c053ab7cc @@ -1216,7 +1216,7 @@ F test/shared6.test 866bb4982c45ce216c61ded5e8fde4e7e2f3ffa9 F test/shared7.test a81e99f83e6c51b02ac99c96fb3a2a7b5978c956 F test/shared8.test 00a07bf5e1337ecf72e94542bdefdc330d7a2538 F test/shared9.test 5f2a8f79b4d6c7d107a01ffa1ed05ae7e6333e21 -F test/sharedA.test 0cdf1a76dfa00e6beee66af5b534b1e8df2720f5 +F test/sharedA.test 49d87ec54ab640fbbc3786ee3c01de94aaa482a3a9f834ad3fe92770eb69e281 F test/sharedB.test 16cc7178e20965d75278f410943109b77b2e645e F test/shared_err.test 32634e404a3317eeb94abc7a099c556a346fdb8fb3858dbe222a4cbb8926a939 F test/sharedlock.test 5ede3c37439067c43b0198f580fd374ebf15d304 @@ -1266,7 +1266,7 @@ F test/sqllimits1.test a74ee2a3740b9f9c2437c246d8fb77354862a142 F test/sqllog.test 6af6cb0b09f4e44e1917e06ce85be7670302517a F test/stat.test f8f1279ffffabe6df825723af18cc6e0ae70a893 F test/statfault.test f525a7bf633e50afd027700e9a486090684b1ac1 -F test/stmt.test 64844332db69cf1a735fcb3e11548557fc95392f +F test/stmt.test 54ed2cc0764bf3e48a058331813c3dbd19fc1d0827c3d8369914a5d8f564ec75 F test/stmtvtab1.test 6873dfb24f8e79cbb5b799b95c2e4349060eb7a3b811982749a84b359468e2d5 F test/subjournal.test 8d4e2572c0ee9a15549f0d8e40863161295107e52f07a3e8012a2e1fdd093c49 F test/subquery.test d7268d193dd33d5505df965399d3a594e76ae13f @@ -1279,9 +1279,9 @@ F test/swarmvtab.test 9a3fd5ab3e9b3c976ad1b3d7646aab725114f2ac26b59395d0778b33ba F test/swarmvtab2.test c948cb2fdfc5b01d85e8f6d6504854202dc1a0782ab2a0ed61538f27cbd0aa5c F test/swarmvtab3.test 6cb664669630fcec4102a09333e52068734858fd2761eee3b0465c14cdbcee29 F test/swarmvtabfault.test 00aec54665909490f5c383f3cae3b5d18bd97c12490b429ff8752a3027acfa42 -F test/symlink.test c9ebe7330d228249e447038276bfc8a7b22f4849 -F test/sync.test 2f84bdbc2b2df1fcb0220575b4b9f8cea94b7529 -F test/sync2.test 6be8ed007fa063b147773c1982b5bdba97a32badc536bdc6077eff5cf8710ece +F test/symlink.test 0d816670325536b8973ec08d32b45136baddb80bd45fd178e0ce7a9e8153f3e7 +F test/sync.test 89539f4973c010eda5638407e71ca7fddbcd8e0594f4c9980229f804d4333092 +F test/sync2.test 8f9f7d4f6d5be8ca8941a8dadcc4299e558cb6a1ff653a9469146c7a76ef2039 F test/syscall.test a39d9a36f852ae6e4800f861bc2f2e83f68bbc2112d9399931ecfadeabd2d69d F test/sysfault.test c9f2b0d8d677558f74de750c75e12a5454719d04 F test/tabfunc01.test c47171c36b3d411df2bd49719dcaa5d034f8d277477fd41d253940723b969a51 @@ -1289,7 +1289,7 @@ F test/table.test b708f3e5fa2542fa51dfab21fc07b36ea445cb2f F test/tableapi.test 2674633fa95d80da917571ebdd759a14d9819126 F test/tableopts.test dba698ba97251017b7c80d738c198d39ab747930 F test/tclsqlite.test c3d7ac9449634b9f17fd048a3c0212e88a7448be810a9c5bd051acc1ffa00d2f -F test/tempdb.test bd92eba8f20e16a9136e434e20b280794de3cdb6 +F test/tempdb.test 4cdaa23ddd8acb4d79cbb1b68ccdfd09b0537aaba909ca69a876157c2a2cbd08 F test/tempdb2.test 27e41ed540b2f9b056c2e77e9bddc1b875358507 F test/tempfault.test 0c0d349c9a99bf5f374655742577f8712c647900 F test/temptable.test d2c9b87a54147161bcd1822e30c1d1cd891e5b30 @@ -1416,7 +1416,7 @@ F test/tkt3357.test 77c37c6482b526fe89941ce951c22d011f5922ed F test/tkt3419.test 1bbf36d7ea03b638c15804251287c2391f5c1f6b F test/tkt3424.test 61f831bd2b071bd128fa5d00fbda57e656ca5812 F test/tkt3442.test 53840ec5325bb94544792aad4c20476f81dc26b1 -F test/tkt3457.test 44e980fe5334753dcc27b94fa4deabc485a92f74 +F test/tkt3457.test 5651e2cbb94645b677ec663160b9e192b87b7d365aecdfb24e19f749575a6fc2 F test/tkt3461.test 228ea328a5a21e8663f80ee3d212a6ad92549a19 F test/tkt3493.test 1686cbde85f8721fc1bdc0ee72f2ef2f63139218 F test/tkt3508.test d75704db9501625c7f7deec119fcaf1696aefb7d @@ -1499,7 +1499,7 @@ F test/vacuum.test ce91c39f7f91a4273bf620efad21086b5aa6ef1d F test/vacuum2.test aa048abee196c16c9ba308465494009057b79f9b F test/vacuum3.test 77ecdd54592b45a0bcb133339f99f1ae0ae94d0d F test/vacuum4.test 7ea76b769fffeb41f925303b04cbcf5a5bbeabe55e4c60ae754ff24eeeb7c010 -F test/vacuum5.test c87234e8ca4107f349da4edbeda3e4ea5adc93f3 +F test/vacuum5.test 263b144d537e92ad8e9ca8a73cc6e1583f41cfd0dda9432b87f7806174a2f48c F test/vacuummem.test 7b42abb3208bd82dd23a7536588396f295a314f2 F test/varint.test bbce22cda8fc4d135bcc2b589574be8410614e62 F test/veryquick.test 57ab846bacf7b90cf4e9a672721ea5c5b669b661 @@ -1526,7 +1526,7 @@ F test/vtab_alter.test 736e66fb5ec7b4fee58229aa3ada2f27ec58bc58c00edae4836890c37 F test/vtab_err.test 0d4d8eb4def1d053ac7c5050df3024fd47a3fbd8 F test/vtab_shared.test 5253bff2355a9a3f014c15337da7e177ab0ef8ad F test/wal.test 613efec03e517e1775d86b993a54877d2e29a477 -F test/wal2.test 2d81ffe2a02d9e5c7447b266f7153716cfcba7aecda5ed832db4544617399e29 +F test/wal2.test 155b9efa999bdb38ce1cd729b9a4fcdbffd6b88be27f039bad1d2929d287d918 F test/wal3.test 2a93004bc0fb2b5c29888964024695bade278ab2 F test/wal4.test 4744e155cd6299c6bd99d3eab1c82f77db9cdb3c F test/wal5.test 9c11da7aeccd83a46d79a556ad11a18d3cb15aa9 @@ -1546,7 +1546,7 @@ F test/walcrash3.test e426aa58122d20f2b9fbe9a507f9eb8cab85b8af F test/walcrash4.test e7b6e7639a950a0cca8e210e248c8dad4d63bf20 F test/walfault.test 1f8389f7709877e9b4cc679033d71d6fe529056b F test/walhook.test ed00a40ba7255da22d6b66433ab61fab16a63483 -F test/walmode.test 4022fe03ae6e830583672caa101f046438a0473c +F test/walmode.test cd6e7cff618eaaa5910ce57c3657aa50110397f86213886a2400afb9bfec7b7b F test/walnoshm.test 84ca10c544632a756467336b7c3b864d493ee496 F test/waloverwrite.test dad2f26567f1b45174e54fbf9a8dc1cb876a7f03 F test/walpersist.test 8c6b7e3ec1ba91b5e4dc4e0921d6d3f87cd356a6 @@ -1599,7 +1599,7 @@ F test/without_rowid6.test 1f99644e6508447fb050f73697350c7ceca3392e F test/wordcount.c cb589cec469a1d90add05b1f8cee75c7210338d87a5afd65260ed5c0f4bbf8ac F test/writecrash.test f1da7f7adfe8d7f09ea79b42e5ca6dcc41102f27f8e334ad71539501ddd910cc F test/zeroblob.test 3857870fe681b8185654414a9bccfde80b62a0fa -F test/zerodamage.test e59a56443d6298ecf7435f618f0b27654f0c849e +F test/zerodamage.test 9c41628db7e8d9e8a0181e59ea5f189df311a9f6ce99cc376dc461f66db6f8dc F test/zipfile.test a5cd98e91aebf343e21a32b97fadd6aefe02d249d5c6a1a3c2e624b88d7bdbe2 F tool/GetFile.cs a15e08acb5dd7539b75ba23501581d7c2b462cb5 F tool/GetTclKit.bat 8995df40c4209808b31f24de0b58f90930239a234f7591e3675d45bfbb990c5d @@ -1699,7 +1699,7 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93 F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0 -P cd7c42699e73b688dbed29ed5d243d06439d7dbe0ba8c42d8299e04cc0dd4464 -R 5af93dd5d7e603d352f9007674349f27 -U mistachkin -Z e985e4fc81de14351414b5000a144309 +P bb196fcb677e962db4308c02097968615729a51fe4a1292e468aaf3e4bf522d3 +R 3bf69d486c995f84804eb3abae6dd335 +U dan +Z ecacbd8e6749e1f68b1f30b320420a3c diff --git a/manifest.uuid b/manifest.uuid index b074e985c2..a32f986633 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -bb196fcb677e962db4308c02097968615729a51fe4a1292e468aaf3e4bf522d3 \ No newline at end of file +56d93d070d6b92d8a5a3fec1b09aae8911116c73d072fc5022f0b51668ed996b \ No newline at end of file diff --git a/test/crash8.test b/test/crash8.test index f3b6f6e244..2c6487b38b 100644 --- a/test/crash8.test +++ b/test/crash8.test @@ -142,6 +142,7 @@ proc write_file {zFile zData} { # b) Less than 512, or # c) Greater than SQLITE_MAX_PAGE_SIZE # +if {[atomic_batch_write test.db]==0} { do_test crash8-3.1 { list [file exists test.db-joural] [file exists test.db] } {0 1} @@ -228,6 +229,7 @@ do_test crash8-3.11 { PRAGMA integrity_check } } {6 ok} +} # If a connection running in persistent-journal mode is part of a @@ -266,8 +268,12 @@ ifcapable pragma { UPDATE aux.ab SET b = randstr(1000,1000) WHERE a>=1; UPDATE ab SET b = randstr(1000,1000) WHERE a>=1; } - list [file exists test.db-journal] [file exists test2.db-journal] - } {1 1} + } {persist persist} + if {[atomic_batch_write test.db]==0} { + do_test crash8.4.1.1 { + list [file exists test.db-journal] [file exists test2.db-journal] + } [list $bJrnl $bJrnl] + } do_test crash8-4.2 { execsql { diff --git a/test/delete_db.test b/test/delete_db.test index 09c44ff9f3..6edd9c242e 100644 --- a/test/delete_db.test +++ b/test/delete_db.test @@ -17,6 +17,11 @@ set testdir [file dirname $argv0] source $testdir/tester.tcl set testprefix delete_db +if {[atomic_batch_write test.db]} { + finish_test + return +} + proc delete_all {} { foreach f [glob -nocomplain test2*] { file delete $f } foreach f [glob -nocomplain test3*] { file delete $f } diff --git a/test/exclusive.test b/test/exclusive.test index 45f9318205..04de529137 100644 --- a/test/exclusive.test +++ b/test/exclusive.test @@ -252,7 +252,9 @@ db2 close # opens the journal file for exclusive access, preventing its contents # from being inspected externally. # -if {$tcl_platform(platform) != "windows"} { +if {$tcl_platform(platform) != "windows" + && [atomic_batch_write test.db]==0 +} { # Return a list of two booleans (either 0 or 1). The first is true # if the named file exists. The second is true only if the file @@ -391,6 +393,7 @@ do_test exclusive-4.5 { # Tests exclusive-5.X - test that statement journals are truncated # instead of deleted when in exclusive access mode. # +if {[atomic_batch_write test.db]==0} { # Close and reopen the database so that the temp database is no # longer active. @@ -508,4 +511,6 @@ do_execsql_test exclusive-6.5 { SELECT * FROM sqlite_master; } {exclusive} +} ;# atomic_batch_write==0 + finish_test diff --git a/test/fallocate.test b/test/fallocate.test index 63d88ea885..0c971c08c1 100644 --- a/test/fallocate.test +++ b/test/fallocate.test @@ -61,6 +61,7 @@ do_test fallocate-1.7 { execsql { BEGIN; INSERT INTO t1 VALUES(1, 2); } if {[permutation] != "inmemory_journal" && [permutation] != "atomic-batch-write" + && [atomic_batch_write test.db]==0 } { hexio_get_int [hexio_read test.db-journal 16 4] } else { diff --git a/test/journal1.test b/test/journal1.test index c89dd2b4c9..bcbafe30f6 100644 --- a/test/journal1.test +++ b/test/journal1.test @@ -22,7 +22,12 @@ source $testdir/tester.tcl # These tests will not work on windows because windows uses # manditory file locking which breaks the copy_file command. # -if {$tcl_platform(platform)=="windows"} { +# Or with atomic_batch_write systems, as journal files are +# not created. +# +if {$tcl_platform(platform)=="windows" + || [atomic_batch_write test.db] +} { finish_test return } diff --git a/test/journal3.test b/test/journal3.test index 939cc27c70..b907352329 100644 --- a/test/journal3.test +++ b/test/journal3.test @@ -20,7 +20,9 @@ source $testdir/malloc_common.tcl # If a connection is required to create a journal file, it creates it with # the same file-system permissions as the database file itself. Test this. # -if {$::tcl_platform(platform) == "unix"} { +if {$::tcl_platform(platform) == "unix" + && [atomic_batch_write test.db]==0 +} { # Changed on 2012-02-13: umask is deliberately ignored for -wal, -journal, # and -shm files. diff --git a/test/jrnlmode.test b/test/jrnlmode.test index 2ba56f2b00..3112f6184e 100644 --- a/test/jrnlmode.test +++ b/test/jrnlmode.test @@ -302,6 +302,7 @@ ifcapable autovacuum&&pragma { # The following test caes, jrnlmode-5.*, test the journal_size_limit # pragma. ifcapable pragma { +if {[atomic_batch_write test.db]==0} { db close forcedelete test.db test2.db test3.db sqlite3 db test.db @@ -454,8 +455,10 @@ ifcapable pragma { list [file exists test.db-journal] [file size test.db-journal] } {1 0} } +} ifcapable pragma { +if {[atomic_batch_write test.db]==0} { # These tests are not run as part of the "journaltest" permutation, # as the test_journal.c layer is incompatible with in-memory journaling. if {[permutation] ne "journaltest"} { @@ -507,6 +510,7 @@ ifcapable pragma { } {0} } } +} ifcapable pragma { catch { db close } diff --git a/test/jrnlmode2.test b/test/jrnlmode2.test index 6ea87d704b..6cc54dc5df 100644 --- a/test/jrnlmode2.test +++ b/test/jrnlmode2.test @@ -18,6 +18,11 @@ ifcapable {!pager_pragmas} { return } +if {[atomic_batch_write test.db]} { + finish_test + return +} + #------------------------------------------------------------------------- # The tests in this file check that the following two bugs (both now fixed) # do not reappear. diff --git a/test/lock4.test b/test/lock4.test index b0b1c74fbe..58dd206997 100644 --- a/test/lock4.test +++ b/test/lock4.test @@ -17,6 +17,14 @@ set testdir [file dirname $argv0] source $testdir/tester.tcl +if {[atomic_batch_write test.db]} { + # This test uses two processes, one of which blocks until the other + # creates a *-journal file. Which doesn't work if atomic writes are + # available. + finish_test + return +} + do_not_use_codec # Initialize the test.db database so that it is non-empty diff --git a/test/pager1.test b/test/pager1.test index 8451e0b3d2..42edc3d16b 100644 --- a/test/pager1.test +++ b/test/pager1.test @@ -17,6 +17,11 @@ source $testdir/malloc_common.tcl source $testdir/wal_common.tcl set testprefix pager1 +if {[atomic_batch_write test.db]} { + finish_test + return +} + # Do not use a codec for tests in this file, as the database file is # manipulated directly using tcl scripts (using the [hexio_write] command). # diff --git a/test/pager3.test b/test/pager3.test index 23435a79b7..e815f2788b 100644 --- a/test/pager3.test +++ b/test/pager3.test @@ -16,6 +16,10 @@ source $testdir/lock_common.tcl source $testdir/malloc_common.tcl source $testdir/wal_common.tcl +if {[atomic_batch_write test.db]} { + finish_test + return +} foreach {tn sql res j} { 1 "PRAGMA journal_mode = DELETE" delete 0 diff --git a/test/rollback.test b/test/rollback.test index 60a6190317..423bf20fce 100644 --- a/test/rollback.test +++ b/test/rollback.test @@ -83,6 +83,7 @@ if {$tcl_platform(platform) == "unix" && [permutation] ne "onefile" && [permutation] ne "inmemory_journal" && [permutation] ne "atomic-batch-write" + && [atomic_batch_write test.db]==0 } { do_test rollback-2.1 { execsql { diff --git a/test/sharedA.test b/test/sharedA.test index 146fb26be0..55ed5749bb 100644 --- a/test/sharedA.test +++ b/test/sharedA.test @@ -19,6 +19,11 @@ if {[run_thread_tests]==0} { finish_test ; return } db close set ::testprefix sharedA +if {[atomic_batch_write test.db]} { + finish_test + return +} + set ::enable_shared_cache [sqlite3_enable_shared_cache 1] #------------------------------------------------------------------------- diff --git a/test/stmt.test b/test/stmt.test index df501f7654..138ce19860 100644 --- a/test/stmt.test +++ b/test/stmt.test @@ -16,6 +16,11 @@ set testdir [file dirname $argv0] source $testdir/tester.tcl +if {[atomic_batch_write test.db]} { + finish_test + return +} + do_test stmt-1.1 { execsql { CREATE TABLE t1(a integer primary key, b INTEGER NOT NULL) } } {} diff --git a/test/symlink.test b/test/symlink.test index 949102cf8a..4695b29fa0 100644 --- a/test/symlink.test +++ b/test/symlink.test @@ -102,7 +102,7 @@ foreach {tn f} {1 test.db2 2 test.db3} { INSERT INTO t1 VALUES(1); } db2 file exists test.db-journal - } 1 + } [expr [atomic_batch_write test.db]==0] do_test 2.$tn.3 { list [file exists test2.db-journal] [file exists test3.db-journal] } {0 0} diff --git a/test/sync.test b/test/sync.test index 210039acb5..023425e6b1 100644 --- a/test/sync.test +++ b/test/sync.test @@ -26,6 +26,10 @@ ifcapable !pager_pragmas||!attach { finish_test return } +if {[atomic_batch_write test.db]} { + finish_test + return +} set sqlite_sync_count 0 proc cond_incr_sync_count {adj} { diff --git a/test/sync2.test b/test/sync2.test index 46e8bc72fb..89e66c8455 100644 --- a/test/sync2.test +++ b/test/sync2.test @@ -29,6 +29,7 @@ ifcapable !pager_pragmas||!attach||!dirsync { if {$::tcl_platform(platform)!="unix" || [permutation] == "journaltest" || [permutation] == "inmemory_journal" + || [atomic_batch_write test.db] } { finish_test return diff --git a/test/tempdb.test b/test/tempdb.test index 61416ec81c..a32ef06f44 100644 --- a/test/tempdb.test +++ b/test/tempdb.test @@ -17,6 +17,11 @@ set testdir [file dirname $argv0] source $testdir/tester.tcl +if {[atomic_batch_write test.db]} { + finish_test + return +} + # Use a temporary database. # db close diff --git a/test/tkt3457.test b/test/tkt3457.test index 0475741322..24b4f0eac0 100644 --- a/test/tkt3457.test +++ b/test/tkt3457.test @@ -19,6 +19,10 @@ if {$tcl_platform(platform) != "unix"} { finish_test return } +if {[atomic_batch_write test.db]} { + finish_test + return +} #----------------------------------------------------------------------- # To roll back a hot-journal file, the application needs read and write diff --git a/test/vacuum5.test b/test/vacuum5.test index 8e76a9393c..f203fb87ba 100644 --- a/test/vacuum5.test +++ b/test/vacuum5.test @@ -143,9 +143,11 @@ if {$::TEMP_STORE<3 && [permutation]!="inmemory_journal"} { db close tvfs delete - do_test 3.2 { - lrange $::openfiles 0 4 - } {test.db test.db-journal test.db-journal {} test.db-journal} + if {[atomic_batch_write test.db]==0} { + do_test 3.2 { + lrange $::openfiles 0 4 + } {test.db test.db-journal test.db-journal {} test.db-journal} + } } diff --git a/test/wal2.test b/test/wal2.test index a9cafec66d..b26f5ca877 100644 --- a/test/wal2.test +++ b/test/wal2.test @@ -584,15 +584,23 @@ do_test wal2-6.3.4 { BEGIN; INSERT INTO t1 VALUES('Groucho'); } - list [file exists test.db-wal] [file exists test.db-journal] -} {0 1} +} {} +if {[atomic_batch_write test.db]==0} { + do_test wal2-6.3.4.1 { + list [file exists test.db-wal] [file exists test.db-journal] + } {0 1} +} do_test wal2-6.3.5 { execsql { PRAGMA lock_status } } {main exclusive temp closed} do_test wal2-6.3.6 { execsql { COMMIT } - list [file exists test.db-wal] [file exists test.db-journal] -} {0 1} +} {} +if {[atomic_batch_write test.db]==0} { + do_test wal2-6.3.6.1 { + list [file exists test.db-wal] [file exists test.db-journal] + } {0 1} +} do_test wal2-6.3.7 { execsql { PRAGMA lock_status } } {main exclusive temp closed} diff --git a/test/walmode.test b/test/walmode.test index 4e14d54d4f..f760823c8d 100644 --- a/test/walmode.test +++ b/test/walmode.test @@ -45,15 +45,17 @@ do_test walmode-1.2 { file size test.db } {1024} -set expected_sync_count 3 -if {$::tcl_platform(platform)!="windows"} { - ifcapable dirsync { - incr expected_sync_count +if {[atomic_batch_write test.db]==0} { + set expected_sync_count 3 + if {$::tcl_platform(platform)!="windows"} { + ifcapable dirsync { + incr expected_sync_count + } } + do_test walmode-1.3 { + set sqlite_sync_count + } $expected_sync_count } -do_test walmode-1.3 { - set sqlite_sync_count -} $expected_sync_count do_test walmode-1.4 { file exists test.db-wal @@ -106,9 +108,11 @@ do_test walmode-4.1 { execsql { INSERT INTO t1 VALUES(1, 2) } execsql { PRAGMA journal_mode = persist } } {persist} -do_test walmode-4.2 { - list [file exists test.db-journal] [file exists test.db-wal] -} {1 0} +if {[atomic_batch_write test.db]==0} { + do_test walmode-4.2 { + list [file exists test.db-journal] [file exists test.db-wal] + } {1 0} +} do_test walmode-4.3 { execsql { SELECT * FROM t1 } } {1 2} @@ -117,9 +121,11 @@ do_test walmode-4.4 { sqlite3 db test.db execsql { SELECT * FROM t1 } } {1 2} -do_test walmode-4.5 { - list [file exists test.db-journal] [file exists test.db-wal] -} {1 0} +if {[atomic_batch_write test.db]==0} { + do_test walmode-4.5 { + list [file exists test.db-journal] [file exists test.db-wal] + } {1 0} +} # Test that nothing goes wrong if a connection is prevented from changing # from WAL to rollback mode because a second connection has the database diff --git a/test/zerodamage.test b/test/zerodamage.test index a87e50b7b5..83bae737df 100644 --- a/test/zerodamage.test +++ b/test/zerodamage.test @@ -74,7 +74,7 @@ do_test zerodamage-2.0 { UPDATE t1 SET y=randomblob(50) WHERE x=123; } concat [file_control_powersafe_overwrite db -1] [set ::max_journal_size] -} {0 1 2576} +} [list 0 1 [expr ([atomic_batch_write test.db]==0)*2576]] # Repeat the previous step with zero-damage turned off. This time the # maximum rollback journal size should be much larger. @@ -87,7 +87,7 @@ do_test zerodamage-2.1 { UPDATE t1 SET y=randomblob(50) WHERE x=124; } concat [file_control_powersafe_overwrite db -1] [set ::max_journal_size] -} {0 0 24704} +} [list 0 0 [expr ([atomic_batch_write test.db]==0)*24704]] if {[wal_is_capable]} { # Run a WAL-mode transaction with POWERSAFE_OVERWRITE on to verify that the