wicket-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Grigorov <mgrigo...@apache.org>
Subject Re: simple automated accessibility testing
Date Tue, 22 Mar 2016 10:21:37 GMT

On Thu, Mar 17, 2016 at 10:47 PM, Boris Goldowsky <bgoldowsky@cast.org>

> I¹m thinking it would be handy to automate testing of the simplest of
> validity & accessibility requirements ­ eg, checking that every <img>
> element has an alt attribute, and every form input has a label.
> Eventually maybe taking this up a notch and connecting with existing HTML
> validation and a11y-checking engines.   As things stand, I have to do any
> such testing manually with browser-based tools.
> Is this something that already exists, or that others would be interested
> in collaborating on?
> I can think of a couple of possible methods that would be pretty general ­
> not sure which is best.
> A) extend WicketTester, adding some assertion methods; then one could
> write a Junit test for each page asserting that it passes certain criteria.
> B) create a runtime checker, something like StatelessChecker, that when
> enabled would check every page as it is rendered.  You could turn this on
> during development to have checking of the actual rendered HTML.
> I¹d be grateful for any thoughts or suggestions.

I think approach A) is better. No need to extend WicketTester though. You
can just introduce a helper class that uses
tester.getLastResponseAsString() and do the checks.

If you go with Approach B) then better use IResponseFilter.
See org.apache.wicket.response.filter.EmptySrcAttributeCheckFilter for

> Boris
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message