--- a/roster_test.go Sun Dec 16 19:55:17 2012 -0700
+++ b/roster_test.go Sun Dec 16 22:17:49 2012 -0700
@@ -13,8 +13,8 @@
// This is mostly just tests of the roster data structures.
func TestRosterIqMarshal(t *testing.T) {
- iq := &Iq{From: "from", Lang: "en",
- Nested: []interface{}{RosterQuery{}}}
+ iq := &Iq{Stanza: Stanza{From: "from", Lang: "en",
+ Nested: []interface{}{RosterQuery{}}}}
exp := `<iq from="from" xml:lang="en"><query xmlns="` +
NsRoster + `"></query></iq>`
assertMarshal(t, exp, iq)
@@ -26,7 +26,7 @@
iq := Iq{}
xml.Unmarshal([]byte(str), &iq)
m := map[string]func(*xml.Name) interface{}{NsRoster: newRosterQuery}
- err := parseExtended(&iq, m)
+ err := parseExtended(&iq.Stanza, m)
if err != nil {
t.Fatalf("parseExtended: %v", err)
}