Commit c13a7bc0 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent d741c8c7
...@@ -516,15 +516,13 @@ func (δBtail *ΔBtail) Update(δZ *zodb.EventCommit) (_ ΔB, err error) { ...@@ -516,15 +516,13 @@ func (δBtail *ΔBtail) Update(δZ *zodb.EventCommit) (_ ΔB, err error) {
δTtail.trackNew = nil // XXX stub δTtail.trackNew = nil // XXX stub
// XXX vvv we can skip computing diff for HEAD~..HEAD (we just // XXX vvv we can skip computing diff for HEAD~..HEAD (we just
// computed it) // computed it in _Update1)
δtrackSet, err := δTtail.rebuild(root, δBtail.δZtail, δBtail.db) δtrackSet, err := δTtail.rebuild(root, δBtail.δZtail, δBtail.db)
if err != nil { if err != nil {
return ΔB{}, err return ΔB{}, err
} }
δBtail.trackSet.UnionInplace(δtrackSet) δBtail.trackSet.UnionInplace(δtrackSet)
// XXX Update δTKeyCov? XXX or it is needed only to be returned
// from treediff?
} }
// build δB. Even if δT=ø after _Update1, but δtkeycov1 != ø, above // build δB. Even if δT=ø after _Update1, but δtkeycov1 != ø, above
......
...@@ -806,6 +806,9 @@ func xverifyΔBTail_Update1(t *testing.T, subj string, db *zodb.DB, treeRoot zod ...@@ -806,6 +806,9 @@ func xverifyΔBTail_Update1(t *testing.T, subj string, db *zodb.DB, treeRoot zod
// δB <- δZ // δB <- δZ
//
// also call _Update1 directly to verify δtkeycov return from treediff
// the result of Update and _Update1 should be the same since δbtail is initially empty.
δbtail_ := δbtail.Clone() δbtail_ := δbtail.Clone()
δB, err := δbtail.Update(δZ); X(err) δB, err := δbtail.Update(δZ); X(err)
δTKeyCov, err := δbtail_._Update1(δZ); X(err) δTKeyCov, err := δbtail_._Update1(δZ); X(err)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment