Sfoglia il codice sorgente

fixes failing tests

tests were failing on expected write.as blog title
previously the title was 'write.as' and it is now 'write.as blog'

also removed test case ExampleClient_GetCollection as was a duplicate of
TestGetCollection
pull/17/head
Rob Loranger 4 anni fa
parent
commit
7c3a6949d5
Non sono state trovate chiavi note per questa firma nel database ID Chiave GPG: D6F1633A4F0903B8
1 ha cambiato i file con 1 aggiunte e 12 eliminazioni
  1. +1
    -12
      collection_test.go

+ 1
- 12
collection_test.go Vedi File

@@ -15,7 +15,7 @@ func TestGetCollection(t *testing.T) {
t.Errorf("Unexpected fetch results: %+v, err: %v\n", res, err)
} else {
t.Logf("Collection: %+v", res)
if res.Title != "write.as" {
if res.Title != "write.as blog" {
t.Errorf("Unexpected fetch results: %+v\n", res)
}
}
@@ -107,14 +107,3 @@ func TestDeleteCollectionUnauthenticated(t *testing.T) {
t.Fatalf("Error message should be more informative: %v", err)
}
}

func ExampleClient_GetCollection() {
c := NewClient()
coll, err := c.GetCollection("blog")
if err != nil {
fmt.Printf("%v", err)
return
}
fmt.Printf("%s", coll.Title)
// Output: write.as
}

Caricamento…
Annulla
Salva