package ii

import (
	"testing"
)

func TestReadDir(t *testing.T) {
	items, err := LoadItems("_test", nil)
	if err != nil {
		t.Error(err)
		return
	}
	for _, item := range items.All() {
		t.Log(item)
	}
}

func TestName(t *testing.T) {
	name := NewNameMust("testDB.testCol")
	t.Log("String:", name.String())
	t.Log("DBName:", name.DbName())
	t.Log("ColName:", name.Collection())
}

func TestSubDeep(t *testing.T) {
	fi, err := ReadFile("_test/test_sub.xml")
	if err != nil {
		panic(err)
	}
	t.Log(fi)
}
