func TestInsertStatement(t *testing.T) { relation := nodes.Relation("table") stmt := nodes.InsertStatement(relation) expected := `INSERT INTO "table" ` if got, _ := sql.Accept(stmt); expected != got { t.Errorf("TestInsertStatement was expected to return %s, got %s", expected, got) } }
func Insertion(relation *nodes.RelationNode) (insertion *InsertManager) { insertion = new(InsertManager) insertion.Tree = nodes.InsertStatement(relation) return }