NAME
Test::XHTML::WAI - Basic WAI compliance checks.
SYNOPSIS
my $txw = Test::XHTML::WAI->new();
$txw->validate($content); # run compliance checks
my $results = $txw->results(); # retrieve results
$txw->clear(); # clear all current errors and results
$txw->errors(); # all current errors reported
$txw->errstr(); # basic error message
$txw->logfile($file); # logfile for verbose messages
$txw->logclean(1); # 1 = overwrite, 0 = append (default)
DESCRIPTION
This module attempts to check WAI compliance. Currently only basic checks are implemented, but more comprehensive checks are planned.
METHODS
Constructor
Enables test object to retain content, results and errors as appropriate.
Public Methods
- level(LEVEL)
-
Level of compliance required to be checked. Valid levels are: 1 (A Level), 2 (AA Level) and 3 (AAA Level). Default level is 1. Invalid level are ignored.
- validate(CONTENT)
-
Checks given content for basic compliance.
- results()
-
Record results to log file (if given) and returns a hashref.
- errors()
-
Returns all the current errors reported as XML::LibXML::Error objects.
- errstr()
-
Returns all the current errors reported as a single string.
- clear()
-
Clear all current errors and results.
- logfile(FILE)
-
Set output log file for verbose messages.
- logclean(STATE)
-
Set STATE to 1 (create/overwrite) or 0 (append - the default)
BUGS, PATCHES & FIXES
There are no known bugs at the time of this release. However, if you spot a bug or are experiencing difficulties, that is not explained within the POD documentation, please send bug reports and patches to barbie@cpan.org.
Fixes are dependent upon their severity and my availability. Should a fix not be forthcoming, please feel free to (politely) remind me.
SEE ALSO
AUTHOR
Barbie, <barbie@cpan.org>
for Miss Barbell Productions <http://www.missbarbell.co.uk>.
COPYRIGHT AND LICENSE
Copyright (C) 2008-2015 Barbie for Miss Barbell Productions.
This distribution is free software; you can redistribute it and/or
modify it under the Artistic Licence v2.