Skip to content

Commit

Permalink
Fix test names and example names
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew McDole committed Apr 11, 2016
1 parent 2b6fabf commit 492b204
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion atom/parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (

// Tests

func TestAtomParser_ParseFeed(t *testing.T) {
func TestParser_Parse(t *testing.T) {
files, _ := filepath.Glob("../testdata/parser/atom/*.xml")
for _, f := range files {
base := filepath.Base(f)
Expand Down
14 changes: 7 additions & 7 deletions parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ func TestDetectFeedType(t *testing.T) {
}
}

func TestFeedParser_ParseFeed(t *testing.T) {
func TestParser_Parse(t *testing.T) {
var feedTests = []struct {
file string
feedType string
Expand Down Expand Up @@ -84,7 +84,7 @@ func TestFeedParser_ParseFeed(t *testing.T) {
}
}

func TestFeedParser_ParseFeedString(t *testing.T) {
func TestParser_ParseString(t *testing.T) {
var feedTests = []struct {
file string
feedType string
Expand Down Expand Up @@ -122,7 +122,7 @@ func TestFeedParser_ParseFeedString(t *testing.T) {
}
}

func TestFeedParser_ParseFeedURL_Success(t *testing.T) {
func TestParser_ParseURL_Success(t *testing.T) {
var feedTests = []struct {
file string
feedType string
Expand Down Expand Up @@ -161,7 +161,7 @@ func TestFeedParser_ParseFeedURL_Success(t *testing.T) {
}
}

func TestFeedParser_ParseFeedURL_Failure(t *testing.T) {
func TestParser_ParseURL_Failure(t *testing.T) {
server, client := mockServerResponse(404, "")
fp := gofeed.NewParser()
fp.Client = client
Expand Down Expand Up @@ -204,7 +204,7 @@ func ExampleDetectFeedType() {
}
}

func ExampleFeedParser_ParseFeed() {
func ExampleParser_Parse() {
feedData := `<rss version="2.0">
<channel>
<title>Sample Feed</title>
Expand All @@ -218,7 +218,7 @@ func ExampleFeedParser_ParseFeed() {
fmt.Println(feed.Title)
}

func ExampleFeedParser_ParseFeedURL() {
func ExampleParser_ParseURL() {
fp := gofeed.NewParser()
feed, err := fp.ParseURL("http://feeds.twit.tv/twit.xml")
if err != nil {
Expand All @@ -227,7 +227,7 @@ func ExampleFeedParser_ParseFeedURL() {
fmt.Println(feed.Title)
}

func ExampleFeedParser_ParseFeedString() {
func ExampleParser_ParseString() {
feedData := `<rss version="2.0">
<channel>
<title>Sample Feed</title>
Expand Down
2 changes: 1 addition & 1 deletion rss/parser_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import (
"github.com/stretchr/testify/assert"
)

func TestRSSParser_ParseFeed(t *testing.T) {
func TestParser_Parse(t *testing.T) {
files, _ := filepath.Glob("../testdata/parser/rss/*.xml")
for _, f := range files {
base := filepath.Base(f)
Expand Down

0 comments on commit 492b204

Please sign in to comment.