Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Unified Diff: third_party/sqlite/src/test/pager2.test

Issue 949043002: Add //third_party/sqlite to dirs_to_snapshot, remove net_sql.patch (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/sqlite/src/test/pager1.test ('k') | third_party/sqlite/src/test/pager4.test » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/sqlite/src/test/pager2.test
diff --git a/third_party/sqlite/src/test/pager2.test b/third_party/sqlite/src/test/pager2.test
index fa5f7b9611bc2b56b7c263c822360e219bd4b442..0e2b33b8339562fb2c7ccf4339123296e464c6c8 100644
--- a/third_party/sqlite/src/test/pager2.test
+++ b/third_party/sqlite/src/test/pager2.test
@@ -118,7 +118,6 @@ tv delete
#-------------------------------------------------------------------------
-#
# pager2-2.1: Test a ROLLBACK with journal_mode=off.
# pager2-2.2: Test shrinking the database (auto-vacuum) with
# journal_mode=off
@@ -148,4 +147,22 @@ do_test pager2-2.2 {
file size test.db
} {3072}
+#-------------------------------------------------------------------------
+# Test that shared in-memory databases seem to work.
+#
+db close
+do_test pager2-3.1 {
+ forcedelete test.db
+ sqlite3_shutdown
+ sqlite3_config_uri 1
+
+ sqlite3 db1 {file:test.db?mode=memory&cache=shared}
+ sqlite3 db2 {file:test.db?mode=memory&cache=shared}
+ sqlite3 db3 test.db
+
+ db1 eval { CREATE TABLE t1(a, b) }
+ db2 eval { INSERT INTO t1 VALUES(1, 2) }
+ list [catch { db3 eval { INSERT INTO t1 VALUES(3, 4) } } msg] $msg
+} {1 {no such table: t1}}
+
finish_test
« no previous file with comments | « third_party/sqlite/src/test/pager1.test ('k') | third_party/sqlite/src/test/pager4.test » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698