Commit f351942d authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent f0df1b1e
......@@ -716,7 +716,7 @@ func testΔBTail(t *testing.T, testq chan ΔBTestEntry) {
// Verify ΔBTail for explicitly provided tree topologies.
func TestΔBTail(t *testing.T) {
// test known cases going through tree1 -> tree2 -> ...
testv := []string {
testv := []interface{} {
"T/B:",
"T/B1:a", // +1
"T/B1:a,2:b", // +2
......@@ -771,8 +771,18 @@ func TestΔBTail(t *testing.T) {
testq := make(chan ΔBTestEntry)
go func() {
defer close(testq)
for _, tree := range testv {
testq <- ΔBTestEntry{tree, nil}
for _, xtest := range testv {
var test ΔBTestEntry
switch xtest := xtest.(type) {
case string:
test.tree = xtest
test.kadjOK = nil
case ΔBTestEntry:
test = xtest
default:
panic(fmt.Sprintf("BUG: bad type in testv: %T", xtest))
}
testq <- test
}
}()
testΔBTail(t, testq)
......
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