mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-30 19:03:16 +03:00
Test that calling sqlite3_db_cacheflush() does not interfere with savepoints.
FossilOrigin-Name: 0e09e4a26938cfe0f573449526a8f0f527cef921
This commit is contained in:
12
manifest
12
manifest
@ -1,5 +1,5 @@
|
|||||||
C Do\snot\sattempt\sto\sflush\sthe\spages\sof\san\sin-memory\sdatabase\sto\sdisk\sif\ssqlite3_db_cacheflush()\sis\scalled.
|
C Test\sthat\scalling\ssqlite3_db_cacheflush()\sdoes\snot\sinterfere\swith\ssavepoints.
|
||||||
D 2015-10-29T21:11:22.422
|
D 2015-10-30T09:13:29.814
|
||||||
F Makefile.in 2ea961bc09e441874eb3d1bf7398e04feb24f3ee
|
F Makefile.in 2ea961bc09e441874eb3d1bf7398e04feb24f3ee
|
||||||
F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
|
F Makefile.linux-gcc 7bc79876b875010e8c8f9502eb935ca92aa3c434
|
||||||
F Makefile.msc 702d3e98f3afc6587a78481257f3c4c900efc3a4
|
F Makefile.msc 702d3e98f3afc6587a78481257f3c4c900efc3a4
|
||||||
@ -503,7 +503,7 @@ F test/btree02.test fe69453d474d8154d19b904157ff1db4812fed99
|
|||||||
F test/btreefault.test c2bcb542685eea44621275cfedbd8a13f65201e3
|
F test/btreefault.test c2bcb542685eea44621275cfedbd8a13f65201e3
|
||||||
F test/busy.test 76b4887f8b9160ba903c1ac22e8ff406ad6ae2f0
|
F test/busy.test 76b4887f8b9160ba903c1ac22e8ff406ad6ae2f0
|
||||||
F test/cache.test 13bc046b26210471ca6f2889aceb1ea52dc717de
|
F test/cache.test 13bc046b26210471ca6f2889aceb1ea52dc717de
|
||||||
F test/cacheflush.test 42855120d2b00ff75033b54ba7693927f1ce4de8
|
F test/cacheflush.test a755c93482ce2e20c04825304bef27e7b7ea0111
|
||||||
F test/capi2.test 011c16da245fdc0106a2785035de6b242c05e738
|
F test/capi2.test 011c16da245fdc0106a2785035de6b242c05e738
|
||||||
F test/capi3.test bf6f0308bbbba1e770dac13aa08e5c2ac61c7324
|
F test/capi3.test bf6f0308bbbba1e770dac13aa08e5c2ac61c7324
|
||||||
F test/capi3b.test efb2b9cfd127efa84433cd7a2d72ce0454ae0dc4
|
F test/capi3b.test efb2b9cfd127efa84433cd7a2d72ce0454ae0dc4
|
||||||
@ -1397,7 +1397,7 @@ F tool/vdbe_profile.tcl 246d0da094856d72d2c12efec03250d71639d19f
|
|||||||
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
|
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
|
||||||
F tool/warnings.sh 48bd54594752d5be3337f12c72f28d2080cb630b
|
F tool/warnings.sh 48bd54594752d5be3337f12c72f28d2080cb630b
|
||||||
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
||||||
P f0cdfb547b0976e753e94958f29cb294edf31bed
|
P 9b79a390440a23542a370b591e567b31ebb35c42
|
||||||
R dcdd2b431259b301d28dfb5e7d9d6d5d
|
R b3b377e425858b0fc40d0f4a8e28ca4d
|
||||||
U dan
|
U dan
|
||||||
Z 1371a31e24aaed4ace229bd9de4453e9
|
Z 2687c0f7a67bbeeb26b2f80bb787cd41
|
||||||
|
@ -1 +1 @@
|
|||||||
9b79a390440a23542a370b591e567b31ebb35c42
|
0e09e4a26938cfe0f573449526a8f0f527cef921
|
@ -229,6 +229,95 @@ do_execsql_test 3.4 {
|
|||||||
SELECT count(*) FROM t2;
|
SELECT count(*) FROM t2;
|
||||||
} {2 2}
|
} {2 2}
|
||||||
|
|
||||||
|
#-------------------------------------------------------------------------
|
||||||
|
# Test that calling sqlite3_db_cacheflush() does not interfere with
|
||||||
|
# savepoint transactions.
|
||||||
|
#
|
||||||
|
do_test 4.0 {
|
||||||
|
reset_db
|
||||||
|
execsql {
|
||||||
|
CREATE TABLE ta(a, aa);
|
||||||
|
CREATE TABLE tb(b, bb);
|
||||||
|
INSERT INTO ta VALUES('a', randomblob(500));
|
||||||
|
INSERT INTO tb VALUES('b', randomblob(500));
|
||||||
|
BEGIN;
|
||||||
|
UPDATE ta SET a = 'A';
|
||||||
|
SAVEPOINT one;
|
||||||
|
UPDATE tb SET b = 'B';
|
||||||
|
}
|
||||||
|
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A B}
|
||||||
|
|
||||||
|
do_test 4.1 {
|
||||||
|
execsql {
|
||||||
|
ROLLBACK TO one;
|
||||||
|
}
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A b}
|
||||||
|
|
||||||
|
do_test 4.2 {
|
||||||
|
execsql {
|
||||||
|
INSERT INTO tb VALUES('c', randomblob(10));
|
||||||
|
INSERT INTO tb VALUES('d', randomblob(10));
|
||||||
|
INSERT INTO tb VALUES('e', randomblob(10));
|
||||||
|
}
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A b c d e}
|
||||||
|
|
||||||
|
do_test 4.3 {
|
||||||
|
execsql {
|
||||||
|
SAVEPOINT two;
|
||||||
|
UPDATE tb SET b = upper(b);
|
||||||
|
}
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A B C D E}
|
||||||
|
|
||||||
|
do_test 4.4 {
|
||||||
|
execsql {
|
||||||
|
ROLLBACK TO two;
|
||||||
|
}
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A b c d e}
|
||||||
|
|
||||||
|
do_test 4.4 {
|
||||||
|
execsql {
|
||||||
|
ROLLBACK TO one;
|
||||||
|
}
|
||||||
|
sqlite3_db_cacheflush db
|
||||||
|
diskquery test.db {
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {A b}
|
||||||
|
|
||||||
|
do_test 4.5 {
|
||||||
|
execsql {
|
||||||
|
ROLLBACK;
|
||||||
|
SELECT a FROM ta;
|
||||||
|
SELECT b FROM tb;
|
||||||
|
}
|
||||||
|
} {a b}
|
||||||
|
|
||||||
test_restore_config_pagecache
|
test_restore_config_pagecache
|
||||||
finish_test
|
finish_test
|
||||||
|
Reference in New Issue
Block a user