domtest

package
v0.7.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 27, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package domtest provides test helpers that parse HTML into spec types.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseReaderDocument

func ParseReaderDocument(t TestingT, r io.Reader) spec.Document

func ParseReaderDocumentFragment

func ParseReaderDocumentFragment(t TestingT, r io.Reader, parent atom.Atom) spec.DocumentFragment

func ParseResponseDocument

func ParseResponseDocument(t TestingT, res *http.Response) spec.Document

func ParseResponseDocumentFragment

func ParseResponseDocumentFragment(t TestingT, res *http.Response, parent atom.Atom) spec.DocumentFragment

func ParseStringDocument

func ParseStringDocument(t TestingT, s string) spec.Document

func ParseStringDocumentFragment added in v0.7.0

func ParseStringDocumentFragment(t TestingT, in string, parent atom.Atom) spec.DocumentFragment

Types

type TestingT

type TestingT interface {
	Helper()
	Error(...any)
	Log(...any)
	Errorf(format string, args ...interface{})
	FailNow()
	Failed() bool
	SkipNow()
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL