mirror of
https://github.com/sqlite/sqlite.git
synced 2025-12-21 13:38:01 +03:00
Add tests demonstrating [d0e803b90344].
FossilOrigin-Name: 7d22ee947ddecb0dc6c640e79c9a09c0931f8b04f97d3ac89afdbf1736312bf7
This commit is contained in:
@@ -1549,6 +1549,9 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
T.assert(blob instanceof Uint8Array).
|
T.assert(blob instanceof Uint8Array).
|
||||||
assert(0x68===blob[0] && 0x69===blob[1]);
|
assert(0x68===blob[0] && 0x69===blob[1]);
|
||||||
blob = null;
|
blob = null;
|
||||||
|
blob = db.selectValue("select ?1", new Uint8Array([97,0,98,0,99]),
|
||||||
|
sqlite3.capi.SQLITE_TEXT);
|
||||||
|
T.assert("a\0b\0c"===blob, "Something is amiss with embedded NULs");
|
||||||
let counter = 0, colNames = [];
|
let counter = 0, colNames = [];
|
||||||
list.length = 0;
|
list.length = 0;
|
||||||
db.exec(new TextEncoder('utf-8').encode("SELECT a a, b b FROM t"),{
|
db.exec(new TextEncoder('utf-8').encode("SELECT a a, b b FROM t"),{
|
||||||
@@ -3715,7 +3718,9 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
.t("Misc. stmt_...", function(sqlite3){
|
.t("Misc. stmt_...", function(sqlite3){
|
||||||
const db = new sqlite3.oo1.DB();
|
const db = new sqlite3.oo1.DB();
|
||||||
db.exec("create table t(a doggiebiscuits); insert into t(a) values(123)");
|
db.exec("create table t(a doggiebiscuits); insert into t(a) values(123)");
|
||||||
const stmt = db.prepare("select a, a+1 from t");
|
let stmt;
|
||||||
|
try{
|
||||||
|
stmt = db.prepare("select a, a+1 from t");
|
||||||
T.assert( stmt.isReadOnly() )
|
T.assert( stmt.isReadOnly() )
|
||||||
.assert( 0===capi.sqlite3_stmt_isexplain(stmt) )
|
.assert( 0===capi.sqlite3_stmt_isexplain(stmt) )
|
||||||
.assert( 0===capi.sqlite3_stmt_explain(stmt, 1) )
|
.assert( 0===capi.sqlite3_stmt_explain(stmt, 1) )
|
||||||
@@ -3750,9 +3755,17 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
}else{
|
}else{
|
||||||
log("Column metadata APIs not enabled");
|
log("Column metadata APIs not enabled");
|
||||||
} // column metadata APIs
|
} // column metadata APIs
|
||||||
|
|
||||||
stmt.finalize();
|
stmt.finalize();
|
||||||
|
stmt = null;
|
||||||
|
stmt = db.prepare("select ?1").bind(new Uint8Array([97,0,98,0,99]));
|
||||||
|
stmt.step();
|
||||||
|
const sv = capi.sqlite3_column_value(stmt,0);
|
||||||
|
T.assert("a\0b\0c"===capi.sqlite3_value_text(sv),
|
||||||
|
"Expecting NULs to have survived.");
|
||||||
|
}finally{
|
||||||
|
if(stmt) stmt.finalize();
|
||||||
db.close();
|
db.close();
|
||||||
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////
|
||||||
|
|||||||
12
manifest
12
manifest
@@ -1,5 +1,5 @@
|
|||||||
C Add\snew\sfile\smissing\sfrom\s[936990cf067a5ebb]\s(and\ssubsequently\sdeleted\sby\sfossil\sclean\s-x).\sHave\sspeedtest1\swasm\suse\sthe\suser-provided\ssqlite3.c,\srather\sthan\sforcing\sthe\scanonical\sone,\sso\sthat\sthe\swasm\sexports\sdon't\shave\sto\sbe\sre-generated\sfor\sthat\sspecial\scase.\sRemove\sa\sharmless\sduplicate\s-D...\sflag.
|
C Add\stests\sdemonstrating\s[d0e803b90344].
|
||||||
D 2025-11-03T21:26:27.965
|
D 2025-11-03T21:38:34.744
|
||||||
F .fossil-settings/binary-glob 61195414528fb3ea9693577e1980230d78a1f8b0a54c78cf1b9b24d0a409ed6a x
|
F .fossil-settings/binary-glob 61195414528fb3ea9693577e1980230d78a1f8b0a54c78cf1b9b24d0a409ed6a x
|
||||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||||
@@ -644,7 +644,7 @@ F ext/wasm/test-opfs-vfs.html 1f2d672f3f3fce810dfd48a8d56914aba22e45c6834e262555
|
|||||||
F ext/wasm/test-opfs-vfs.js 1618670e466f424aa289859fe0ec8ded223e42e9e69b5c851f809baaaca1a00c
|
F ext/wasm/test-opfs-vfs.js 1618670e466f424aa289859fe0ec8ded223e42e9e69b5c851f809baaaca1a00c
|
||||||
F ext/wasm/tester1-worker.c-pp.html 0e432ec2c0d99cd470484337066e8d27e7aee4641d97115338f7d962bf7b081a
|
F ext/wasm/tester1-worker.c-pp.html 0e432ec2c0d99cd470484337066e8d27e7aee4641d97115338f7d962bf7b081a
|
||||||
F ext/wasm/tester1.c-pp.html 52d88fe2c6f21a046030a36410b4839b632f4424028197a45a3d5669ea724ddb
|
F ext/wasm/tester1.c-pp.html 52d88fe2c6f21a046030a36410b4839b632f4424028197a45a3d5669ea724ddb
|
||||||
F ext/wasm/tester1.c-pp.js 2b014884dadf28928fabcb688746ca87145673eef75e154486505a266203fc15
|
F ext/wasm/tester1.c-pp.js 1eb1d603fc5f0aa92f503bc41a7586599c7cd2fdd562415dbf9ba00aadd071d3
|
||||||
F ext/wasm/tests/opfs/concurrency/index.html 657578a6e9ce1e9b8be951549ed93a6a471f4520a99e5b545928668f4285fb5e
|
F ext/wasm/tests/opfs/concurrency/index.html 657578a6e9ce1e9b8be951549ed93a6a471f4520a99e5b545928668f4285fb5e
|
||||||
F ext/wasm/tests/opfs/concurrency/test.js d08889a5bb6e61937d0b8cbb78c9efbefbf65ad09f510589c779b7cc6a803a88
|
F ext/wasm/tests/opfs/concurrency/test.js d08889a5bb6e61937d0b8cbb78c9efbefbf65ad09f510589c779b7cc6a803a88
|
||||||
F ext/wasm/tests/opfs/concurrency/worker.js 0a8c1a3e6ebb38aabbee24f122693f1fb29d599948915c76906681bb7da1d3d2
|
F ext/wasm/tests/opfs/concurrency/worker.js 0a8c1a3e6ebb38aabbee24f122693f1fb29d599948915c76906681bb7da1d3d2
|
||||||
@@ -2167,8 +2167,8 @@ F tool/version-info.c 33d0390ef484b3b1cb685d59362be891ea162123cea181cb8e6d2cf6dd
|
|||||||
F tool/warnings-clang.sh bbf6a1e685e534c92ec2bfba5b1745f34fb6f0bc2a362850723a9ee87c1b31a7
|
F tool/warnings-clang.sh bbf6a1e685e534c92ec2bfba5b1745f34fb6f0bc2a362850723a9ee87c1b31a7
|
||||||
F tool/warnings.sh d924598cf2f55a4ecbc2aeb055c10bd5f48114793e7ba25f9585435da29e7e98
|
F tool/warnings.sh d924598cf2f55a4ecbc2aeb055c10bd5f48114793e7ba25f9585435da29e7e98
|
||||||
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
||||||
P 936990cf067a5ebb34f7f662fc2d23d468c50f179afafe47fe0d2ed775f5ef74
|
P 7a592f5cd09699b45051855f6d477def40220b17642cbdb0f35ed74dd32becf1
|
||||||
R 65b12beea2ff752a582a42be06dddd6f
|
R eb4c3dac7c2a6cda27cf9d3d886336ce
|
||||||
U stephan
|
U stephan
|
||||||
Z f58f7201c6d9f1b20fefdd1295aff400
|
Z 1e9568cd573e5fe4d4bd6b9f3ad90e5c
|
||||||
# Remove this line to create a well-formed Fossil manifest.
|
# Remove this line to create a well-formed Fossil manifest.
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
7a592f5cd09699b45051855f6d477def40220b17642cbdb0f35ed74dd32becf1
|
7d22ee947ddecb0dc6c640e79c9a09c0931f8b04f97d3ac89afdbf1736312bf7
|
||||||
|
|||||||
Reference in New Issue
Block a user