aboutsummaryrefslogtreecommitdiff
path: root/crawler_test.go
diff options
context:
space:
mode:
Diffstat (limited to 'crawler_test.go')
-rw-r--r--crawler_test.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/crawler_test.go b/crawler_test.go
index 7b5c92c..0ad469b 100644
--- a/crawler_test.go
+++ b/crawler_test.go
@@ -33,11 +33,11 @@ func TestCrawler(t *testing.T) {
)
var crawledPages int
- h := HandlerFunc(func(c *Crawler, u string, depth int, resp *http.Response, err error) error {
+ h := HandlerFunc(func(p Publisher, u string, depth int, resp *http.Response, err error) error {
crawledPages++
next := fmt.Sprintf(srv.URL+"/page/%d", crawledPages)
log.Printf("%s -> %s", u, next)
- c.Enqueue(Outlink{
+ p.Enqueue(Outlink{
URL: mustParseURL(next),
Tag: TagPrimary,
}, depth+1)