Group array support; ToString() support

This commit is contained in:
eanderton
2014-07-07 20:48:29 -04:00
parent b28c2d0c9e
commit c8b5633273
5 changed files with 274 additions and 16 deletions
+24
View File
@@ -1 +1,25 @@
package toml
import (
"testing"
)
func TestTomlGetPath(t *testing.T) {
node := make(TomlTree)
//TODO: set other node data
for idx, item := range []struct {
Path []string
Expected interface{}
} {
{ // empty path test
[]string{},
&node,
},
} {
result := node.GetPath(item.Path)
if result != item.Expected {
t.Errorf("GetPath[%d] %v - expected %v, got %v instead.", idx, item.Path, item.Expected, result)
}
}
}