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

@@ -333,6 +333,7 @@ export default function extendConnector (Y/* :any */) {
})
this.syncStep2 = defer.promise
let m /* :MessageSyncStep2 */ = message
// apply operations first
db.requestTransaction(function * () {
yield * this.applyDeleteSet(m.deleteSet)
if (m.osUntransformed != null) {
@@ -340,27 +341,15 @@ export default function extendConnector (Y/* :any */) {
} else {
this.store.apply(m.os)
}
/*
* This just sends the complete hb after some time
* Mostly for debugging..
*
db.requestTransaction(function * () {
var ops = yield* this.getOperations(m.stateSet)
if (ops.length > 0) {
if (!broadcastHB) { // TODO: consider to broadcast here..
conn.send(sender, {
type: 'update',
ops: ops
})
} else {
// broadcast only once!
conn.broadcastOps(ops)
}
}
})
*/
defer.resolve()
})
/* then apply ds
db.whenTransactionsFinished().then(() => {
db.requestTransaction(function * () {
yield * this.applyDeleteSet(m.deleteSet)
})
defer.resolve()
})*/
return this.syncStep2
} else if (message.type === 'sync done') {
var self = this