Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
032f76d2
Commit
032f76d2
authored
Jul 09, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
38b7a487
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
8 deletions
+24
-8
wcfs/internal/xbtree/δbtail_test.go
wcfs/internal/xbtree/δbtail_test.go
+3
-3
wcfs/internal/zdata/δftail.go
wcfs/internal/zdata/δftail.go
+1
-1
wcfs/internal/zdata/δftail_test.go
wcfs/internal/zdata/δftail_test.go
+20
-4
No files found.
wcfs/internal/xbtree/δbtail_test.go
View file @
032f76d2
...
...
@@ -36,7 +36,7 @@ package xbtree
// b) transition a BTree in ZODB through random tree topologies and feed
// ΔBtail through created database transactions.
//
// TestΔBTail and TestΔBTail
AllStructs
implement approaches "a" and "b" correspondingly.
// TestΔBTail and TestΔBTail
Random
implement approaches "a" and "b" correspondingly.
//
// testprog/treegen.py is used as helper to both: XXX moved to xbtreetest
//
...
...
@@ -1353,8 +1353,8 @@ func TestΔBTail(t *testing.T) {
}
// TestΔBTail
AllStructs verifies ΔBtail on
tree topologies generated by AllStructs.
func
TestΔBTail
AllStructs
(
t
*
testing
.
T
)
{
// TestΔBTail
Random verifies ΔBtail on random
tree topologies generated by AllStructs.
func
TestΔBTail
Random
(
t
*
testing
.
T
)
{
X
:=
exc
.
Raiseif
// considerations:
...
...
wcfs/internal/zdata/δftail.go
View file @
032f76d2
...
...
@@ -79,6 +79,7 @@ type ΔFtail struct {
trackSetZFile
setOid
// set of tracked ZBigFiles as of @head
trackSetZBlk
map
[
zodb
.
Oid
]
*
zblkTrack
// zblk -> {} root -> {}blk as of @head
// XXX kill
///*
// XXX don't need vδF - everything is reconstructed at runtime from .δBtail.vδT
...
...
@@ -249,7 +250,6 @@ func (δFtail *ΔFtail) Update(δZ *zodb.EventCommit) (_ ΔF, err error) {
δF
.
ByFile
[
file
]
=
δfile
}
for
blk
/*, zblk*/
:=
range
δt
{
// FIXME stub - need to take both keys and zblk changes into account
// XXX document, and in particular how to include atTail
δfile
.
Blocks
.
Add
(
blk
)
}
...
...
wcfs/internal/zdata/δftail_test.go
View file @
032f76d2
...
...
@@ -20,10 +20,26 @@
package
zdata
// tests for δftail.go
//
// This are the main tests for ΔFtail functionality.
// XXX overview
// XXX we assume that ΔBtail works correctly (this is covered by ΔBtail tests)
// XXX -> no need to exercise many different topologies and tracking sets.
// This are the main tests for ΔFtail functionality. The primary testing
// concern is to verify how ΔFtail merges ΔBtail and ΔZtail histories on Update
// and queries.
//
// We assume that ΔBtail works correctly (this is covered by ΔBtail tests)
// -> no need to exercise many different topologies and tracking sets.
//
// Since ΔFtail does not recompute anything by itself when tracking set
// changes, and only merges δBtail and δZtail histories on queries, there is no
// need to exercise many different tracking sets. Once again we assume that
// ΔBtail works correctly and verify δFtail only with track=[-∞,∞).
//
// There are 2 testing approaches:
//
// a) transition a ZBigFile in ZODB through particular .blktab and ZBlk
// states and feed ΔFtail through created database transactions.
// b) transition a ZBigFile in ZODB through random .blktab and ZBlk
// states and feed ΔFtail through created database transactions.
//
// TestΔFtail and TestΔFtail implement approaches "a" and "b" correspondingly.
import
(
"context"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment