mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-29 08:01:23 +03:00
Minor JS test cleanups prompted by a linter.
FossilOrigin-Name: 764235a3d15fda55af85ebe3b5885fa27336cc0e979f1be2f6770b66a84bbe87
This commit is contained in:
@ -1345,7 +1345,7 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
.assert(pVfsDb > 0)
|
.assert(pVfsDb > 0)
|
||||||
.assert(pVfsMem !== pVfsDflt
|
.assert(pVfsMem !== pVfsDflt
|
||||||
/* memdb lives on top of the default vfs */)
|
/* memdb lives on top of the default vfs */)
|
||||||
.assert(pVfsDb === pVfsDflt || pVfsdb === pVfsMem)
|
.assert(pVfsDb === pVfsDflt || pVfsDb === pVfsMem)
|
||||||
;
|
;
|
||||||
/*const vMem = new capi.sqlite3_vfs(pVfsMem),
|
/*const vMem = new capi.sqlite3_vfs(pVfsMem),
|
||||||
vDflt = new capi.sqlite3_vfs(pVfsDflt),
|
vDflt = new capi.sqlite3_vfs(pVfsDflt),
|
||||||
@ -2188,7 +2188,7 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
"back into JS because of the lack of 64-bit integer support.");
|
"back into JS because of the lack of 64-bit integer support.");
|
||||||
}
|
}
|
||||||
}finally{
|
}finally{
|
||||||
const x = w.scopedAlloc(1), y = w.scopedAlloc(1), z = w.scopedAlloc(1);
|
//const x = w.scopedAlloc(1), y = w.scopedAlloc(1), z = w.scopedAlloc(1);
|
||||||
//log("x=",x,"y=",y,"z=",z); // just looking at the alignment
|
//log("x=",x,"y=",y,"z=",z); // just looking at the alignment
|
||||||
w.scopedAllocPop(stack);
|
w.scopedAllocPop(stack);
|
||||||
}
|
}
|
||||||
@ -2851,6 +2851,7 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
},
|
},
|
||||||
9
|
9
|
||||||
);
|
);
|
||||||
|
T.assert( 0==rc );
|
||||||
db.transaction((d)=>{
|
db.transaction((d)=>{
|
||||||
d.exec([
|
d.exec([
|
||||||
"create table t(a);",
|
"create table t(a);",
|
||||||
@ -2864,8 +2865,10 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
.assert(2 === countHook[capi.SQLITE_UPDATE])
|
.assert(2 === countHook[capi.SQLITE_UPDATE])
|
||||||
.assert(1 === countHook[capi.SQLITE_DELETE]);
|
.assert(1 === countHook[capi.SQLITE_DELETE]);
|
||||||
//wasm.xWrap.FuncPtrAdapter.debugFuncInstall = true;
|
//wasm.xWrap.FuncPtrAdapter.debugFuncInstall = true;
|
||||||
db.close();
|
T.assert( !!capi.sqlite3_preupdate_hook(db, 0, 0) );
|
||||||
//wasm.xWrap.FuncPtrAdapter.debugFuncInstall = false;
|
//wasm.xWrap.FuncPtrAdapter.debugFuncInstall = false;
|
||||||
|
T.assert( !capi.sqlite3_preupdate_hook(db, 0, 0) );
|
||||||
|
db.close();
|
||||||
}
|
}
|
||||||
})/*pre-update hooks*/
|
})/*pre-update hooks*/
|
||||||
;/*end hook API tests*/
|
;/*end hook API tests*/
|
||||||
@ -3066,7 +3069,7 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
T.assert(6 === db.selectValue('select count(*) from p')).
|
T.assert(6 === db.selectValue('select count(*) from p')).
|
||||||
assert( this.opfsImportSize == exp.byteLength );
|
assert( this.opfsImportSize == exp.byteLength );
|
||||||
db.close();
|
db.close();
|
||||||
const unlink = this.opfsUnlink =
|
this.opfsUnlink =
|
||||||
(fn=filename)=>sqlite3.util.sqlite3__wasm_vfs_unlink("opfs",fn);
|
(fn=filename)=>sqlite3.util.sqlite3__wasm_vfs_unlink("opfs",fn);
|
||||||
this.opfsUnlink(filename);
|
this.opfsUnlink(filename);
|
||||||
T.assert(!(await sqlite3.opfs.entryExists(filename)));
|
T.assert(!(await sqlite3.opfs.entryExists(filename)));
|
||||||
@ -3447,10 +3450,10 @@ globalThis.sqlite3InitModule = sqlite3InitModule;
|
|||||||
sql: "SELECT * FROM f order by path",
|
sql: "SELECT * FROM f order by path",
|
||||||
rowMode: 'array'
|
rowMode: 'array'
|
||||||
});
|
});
|
||||||
const dump = function(lbl){
|
/*const dump = function(lbl){
|
||||||
let rc = fetchEm();
|
let rc = fetchEm();
|
||||||
log((lbl ? (lbl+' results') : ''),rc);
|
log((lbl ? (lbl+' results') : ''),rc);
|
||||||
};
|
};*/
|
||||||
//dump('Full fts table');
|
//dump('Full fts table');
|
||||||
let rc = fetchEm();
|
let rc = fetchEm();
|
||||||
T.assert(3===rc.length);
|
T.assert(3===rc.length);
|
||||||
|
12
manifest
12
manifest
@ -1,5 +1,5 @@
|
|||||||
C Remove\ssome\sduplicated\sJS\stests.
|
C Minor\sJS\stest\scleanups\sprompted\sby\sa\slinter.
|
||||||
D 2025-06-21T16:18:23.575
|
D 2025-06-21T16:33:05.299
|
||||||
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
|
||||||
@ -698,7 +698,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.html ebc4b820a128963afce328ecf63ab200bd923309eb939f4110510ab449e9814c
|
F ext/wasm/tester1-worker.html ebc4b820a128963afce328ecf63ab200bd923309eb939f4110510ab449e9814c
|
||||||
F ext/wasm/tester1.c-pp.html 1c1bc78b858af2019e663b1a31e76657b73dc24bede28ca92fbe917c3a972af2
|
F ext/wasm/tester1.c-pp.html 1c1bc78b858af2019e663b1a31e76657b73dc24bede28ca92fbe917c3a972af2
|
||||||
F ext/wasm/tester1.c-pp.js f1d5716afbce357b62f499cf9a122cfa2858ec48c3bf648977ffa16c75637e3b
|
F ext/wasm/tester1.c-pp.js 766a2ba51a2619d41a49be7c6a1ad014c1d23fc97b67496e4f103038203eb17d
|
||||||
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
|
||||||
@ -2208,8 +2208,8 @@ F tool/version-info.c 3b36468a90faf1bbd59c65fd0eb66522d9f941eedd364fabccd7227350
|
|||||||
F tool/warnings-clang.sh bbf6a1e685e534c92ec2bfba5b1745f34fb6f0bc2a362850723a9ee87c1b31a7
|
F tool/warnings-clang.sh bbf6a1e685e534c92ec2bfba5b1745f34fb6f0bc2a362850723a9ee87c1b31a7
|
||||||
F tool/warnings.sh 1ad0169b022b280bcaaf94a7fa231591be96b514230ab5c98fbf15cd7df842dd
|
F tool/warnings.sh 1ad0169b022b280bcaaf94a7fa231591be96b514230ab5c98fbf15cd7df842dd
|
||||||
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
|
||||||
P b77b3adc828ce543e880e230701edd5e0ccb681e4c3c724ea8ad5ecbd69c73a6
|
P d1cb9ed79d806f667c22f5ba9861451d4d0765aa3072e085831045cf3a39f8b4
|
||||||
R a3f6d928e74b29e4c081c31344d3d11b
|
R 15590cab672738df1152880b649ad09c
|
||||||
U stephan
|
U stephan
|
||||||
Z b7cb84e3623cf8841c3eaae1a4ae5342
|
Z cb0a3872dca8ee115c5d9ebe23218098
|
||||||
# Remove this line to create a well-formed Fossil manifest.
|
# Remove this line to create a well-formed Fossil manifest.
|
||||||
|
@ -1 +1 @@
|
|||||||
d1cb9ed79d806f667c22f5ba9861451d4d0765aa3072e085831045cf3a39f8b4
|
764235a3d15fda55af85ebe3b5885fa27336cc0e979f1be2f6770b66a84bbe87
|
||||||
|
Reference in New Issue
Block a user