From 2eea0c0a703e32b904741d52c9e2c9ae836c14b0 Mon Sep 17 00:00:00 2001 From: Samuel Stauffer Date: Wed, 19 Mar 2014 14:22:55 -0700 Subject: Use error instead of *Error --- ldap_test.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'ldap_test.go') diff --git a/ldap_test.go b/ldap_test.go index 48023f1..31cfbf0 100644 --- a/ldap_test.go +++ b/ldap_test.go @@ -20,7 +20,7 @@ func TestConnect(t *testing.T) { fmt.Printf("TestConnect: starting...\n") l, err := Dial("tcp", fmt.Sprintf("%s:%d", ldapServer, ldapPort)) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } defer l.Close() @@ -31,7 +31,7 @@ func TestSearch(t *testing.T) { fmt.Printf("TestSearch: starting...\n") l, err := Dial("tcp", fmt.Sprintf("%s:%d", ldapServer, ldapPort)) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } defer l.Close() @@ -45,7 +45,7 @@ func TestSearch(t *testing.T) { sr, err := l.Search(searchRequest) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } @@ -56,14 +56,14 @@ func TestSearchWithPaging(t *testing.T) { fmt.Printf("TestSearchWithPaging: starting...\n") l, err := Dial("tcp", fmt.Sprintf("%s:%d", ldapServer, ldapPort)) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } defer l.Close() err = l.Bind("", "") if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } @@ -75,7 +75,7 @@ func TestSearchWithPaging(t *testing.T) { nil) sr, err := l.SearchWithPaging(searchRequest, 5) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } @@ -91,7 +91,7 @@ func testMultiGoroutineSearch(t *testing.T, l *Conn, results chan *SearchResult, nil) sr, err := l.Search(searchRequest) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) results <- nil return } @@ -102,7 +102,7 @@ func TestMultiGoroutineSearch(t *testing.T) { fmt.Printf("TestMultiGoroutineSearch: starting...\n") l, err := Dial("tcp", fmt.Sprintf("%s:%d", ldapServer, ldapPort)) if err != nil { - t.Errorf(err.String()) + t.Errorf(err.Error()) return } defer l.Close() -- cgit v1.2.3