enable gc in random tests

This commit is contained in:
Kevin Jahns
2017-06-19 21:16:42 +02:00
parent dfe3b0b1d1
commit 060549f2cb
4 changed files with 35 additions and 29 deletions

View File

@@ -80,6 +80,10 @@ export default function extendDatabase (Y /* :any */) {
function garbageCollect () {
return os.whenTransactionsFinished().then(function () {
if (os.gcTimeout > 0 && (os.gc1.length > 0 || os.gc2.length > 0)) {
// debug
if (os.y.connector.isSynced === false) {
debugger
}
if (!os.y.connector.isSynced) {
console.warn('gc should be empty when not synced!')
}