Added more tests and refactored exporter tests. Added code coverage badge.

This commit is contained in:
Musab Gültekin
2019-07-02 14:53:06 +03:00
parent 4ab7cfd904
commit b355a566cf
9 changed files with 144 additions and 17 deletions

View File

@ -28,7 +28,7 @@ func (r *Response) JoinURL(relativeURL string) string {
return joinedURL.String()
}
// IsHTML checks if response content is HTML by looking to content-type header
// IsHTML checks if response content is HTML by looking content-type header
func (r *Response) IsHTML() bool {
contentType := r.Header.Get("Content-Type")
for _, htmlContentType := range []string{"text/html", "application/xhtml+xml", "application/vnd.wap.xhtml+xml"} {