surf icon indicating copy to clipboard operation
surf copied to clipboard

browser.Title() incorrect behaviour

Open nsmith5 opened this issue 6 years ago • 0 comments

browser.Title() matches all title tags, but should only match one in the head section.

Example

package main

import (
	"gopkg.in/headzoo/surf.v1"
	"fmt"
)

func main() {
	bow := surf.NewBrowser()
	err := bow.Open("http://golang.org")
	if err != nil {
		panic(err)
	}

	// Outputs: "The Go Programming Language"
	fmt.Println(bow.Title())
}

Expected behaviour: prints 'The Go Programming Language' Actual behaviour: prints 'The Go Programming Languagesubmit search'.

nsmith5 avatar Mar 16 '18 18:03 nsmith5