Fix benchmarks

This commit is contained in:
2026-02-25 12:16:44 +11:00
parent fe68cf2459
commit 99b9ffacca
2 changed files with 18 additions and 2 deletions

View File

@@ -35,4 +35,18 @@ const retrievedDataEncrypted = await storageEncrypted.findOne({ name: 'test' });
console.log(retrievedData); console.log(retrievedData);
// console.log(retrievedDataSynced); // console.log(retrievedDataSynced);
console.log(retrievedDataEncrypted); console.log(retrievedDataEncrypted);
// Update data in storage
await storage.updateOne({ id: 'test' }, { name: 'test2' });
await storageEncrypted.updateOne({ id: 'test' }, { name: 'test2' });
// Retrieve data from storage
const retrievedDataUpdated = await storage.findOne({ name: 'test2' });
// const retrievedDataSynced = await storageSynced.findOne('test');
const retrievedDataEncryptedUpdated = await storageEncrypted.findOne({ name: 'test2' });
console.log(retrievedDataUpdated);
// console.log(retrievedDataSynced);
console.log(retrievedDataEncryptedUpdated);

View File

@@ -6,7 +6,9 @@
"scripts": { "scripts": {
"build": "tsc", "build": "tsc",
"format": "prettier --write .", "format": "prettier --write .",
"test": "echo \"Error: no test specified\" && exit 1" "test": "echo \"Error: no test specified\" && exit 1",
"benchmark:storage": "tsx benchmarks/storage.ts"
}, },
"keywords": [], "keywords": [],
"author": "", "author": "",