xmpp_test.go
changeset 31 1dc47df5c99f
parent 24 fff79efe06f6
child 34 7b1f924c75e2
--- a/xmpp_test.go	Thu Dec 29 11:11:18 2011 -0700
+++ b/xmpp_test.go	Thu Dec 29 11:17:52 2011 -0700
@@ -18,7 +18,7 @@
 	ch := make(chan interface{})
 	go readXml(r, ch)
 	x := <- ch
-	se, ok := x.(*StreamError)
+	se, ok := x.(*streamError)
 	if !ok {
 		t.Fatalf("not StreamError: %v", reflect.TypeOf(x))
 	}
@@ -34,7 +34,7 @@
 	ch = make(chan interface{})
 	go readXml(r, ch)
 	x = <- ch
-	se, ok = x.(*StreamError)
+	se, ok = x.(*streamError)
 	if !ok {
 		t.Fatalf("not StreamError: %v", reflect.TypeOf(x))
 	}
@@ -78,13 +78,13 @@
 }
 
 func TestWriteError(t *testing.T) {
-	se := &StreamError{Any: Generic{XMLName: xml.Name{Local:
+	se := &streamError{Any: Generic{XMLName: xml.Name{Local:
 				"blah"}}}
 	str := testWrite(se)
 	exp := `<stream:error><blah></blah></stream:error>`
 	assertEquals(t, exp, str)
 
-	se = &StreamError{Any: Generic{XMLName: xml.Name{Space:
+	se = &streamError{Any: Generic{XMLName: xml.Name{Space:
 				nsStreams, Local: "foo"}}, Text:
 		&errText{Lang: "ru", Text: "Пошёл ты"}}
 	str = testWrite(se)