mirror of
https://github.com/orbitdb/orbitdb.git
synced 2025-10-07 22:57:07 +00:00
Test/database (#38)
* test: Database. * test: Remove caching test. Caching is superseded by the various storage options. * test: db2 replicates data in existing db1. * test: Move event tests to generic database tests. * test: Single instance cleanup. * fix: Linting. * Fix Sync race condition (#39) * test: Fix key path import. --------- Co-authored-by: Haad <haadcode@users.noreply.github.com>
This commit is contained in:
@@ -39,7 +39,9 @@ const Database = async ({ OpLog, ipfs, identity, address, name, accessController
|
||||
events.emit('update', entry)
|
||||
return entry.hash
|
||||
}
|
||||
return queue.add(task)
|
||||
const hash = await queue.add(task)
|
||||
await queue.onIdle()
|
||||
return hash
|
||||
}
|
||||
|
||||
const applyOperation = async (bytes) => {
|
||||
@@ -53,7 +55,6 @@ const Database = async ({ OpLog, ipfs, identity, address, name, accessController
|
||||
}
|
||||
}
|
||||
await queue.add(task)
|
||||
await queue.onIdle()
|
||||
}
|
||||
|
||||
const close = async () => {
|
||||
|
||||
Reference in New Issue
Block a user