Add arbotree interface wrapper

This commit is contained in:
arnaucube
2021-05-08 17:12:24 +02:00
parent 38ff9dd0e3
commit 88cbe4f29f
4 changed files with 2236 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
package arbotree
import (
"testing"
"go.vocdoni.io/dvote/censustree"
)
func TestInterface(t *testing.T) {
storage := t.TempDir()
tree := &Tree{}
err := tree.Init("test", storage)
if err != nil {
t.Fatal(err)
}
var i interface{} = tree
_, ok := i.(censustree.Tree)
if !ok {
t.Fatal("censustree interface not matched by arbotree wrapper")
}
}