Documentation ¶
Overview ¶
Package htmltest : Main package, provides the HTMLTest struct and associated checks.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DefaultOptions ¶
func DefaultOptions() map[string]interface{}
DefaultOptions returns a map of default options.
Types ¶
type HTMLTest ¶ added in v0.3.0
type HTMLTest struct {
// contains filtered or unexported fields
}
HTMLTest struct, A html testing session, user options are passed in and tests are run.
func (*HTMLTest) CountDocuments ¶ added in v0.4.0
CountDocuments : Return number of documents in hT document store
func (*HTMLTest) CountErrors ¶ added in v0.3.0
CountErrors : Return number of error level issues
type Options ¶
type Options struct { DirectoryPath string DirectoryIndex string FilePath string FileExtension string CheckDoctype bool CheckAnchors bool CheckLinks bool CheckImages bool CheckScripts bool CheckMeta bool CheckGeneric bool CheckExternal bool CheckInternal bool CheckInternalHash bool CheckMailto bool CheckTel bool CheckFavicon bool CheckMetaRefresh bool EnforceHTML5 bool EnforceHTTPS bool IgnoreURLs []interface{} IgnoreDirs []interface{} IgnoreInternalEmptyHash bool IgnoreCanonicalBrokenLinks bool IgnoreAltMissing bool IgnoreDirectoryMissingTrailingSlash bool IgnoreTagAttribute string TestFilesConcurrently bool DocumentConcurrencyLimit int HTTPConcurrencyLimit int LogLevel int LogSort string ExternalTimeout int StripQueryString bool StripQueryExcludes []string EnableCache bool EnableLog bool OutputDir string OutputCacheFile string OutputLogFile string CacheExpires string // Accepts golang time period strings, hours (16h) is really only useful option // --- Internals below here --- NoRun bool // When true does not run tests, used to inspect state in unit tests VCREnable bool // When true patches the govcr httpClient to mock network calls }
Options struct for htmltest, user and default options are merged and mapped into an instance of this struct.
Click to show internal directories.
Click to hide internal directories.