I hadn't considered using an online validator.  Given that these are
only unit tests, this is the simplest solution.  Thanks!

On Dec 18, 7:27 pm, Jeff Valk <jv-li...@tx.rr.com> wrote:
> On Saturday, December 18, 2010 at 02:10 pm, Alyssa Kwan wrote:
>
> > I'd like to unit test my html output for well-formedness.  What's an
> > easy way to test it for HTML5 validity?  Are there good Clojure libs
> > for this?  I only need to check for validity, not parse.
>
> I'm not aware of a native clojure html validator. That said, the first thing 
> that comes to mind is to use something like clj-http [1] to post your markup 
> to the w3c validator [2]. If you're doing this often, or offline, you could 
> run the validator locally [3].
>
> As a bonus, this method would get you validation for css, rss/atom, etc with 
> miminal extra effort. Perhaps you've already considered this, but I figured 
> I'd toss it out there anyway. Good luck!
>
> - Jeff
>
> [1]https://github.com/clj-sys/clj-http
> [2]http://validator.w3.org/#validate_by_input
> [3]http://validator.w3.org/docs/install.html
>     (also in the debian/ubuntu repos as "w3c-markup-validator")

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en

Reply via email to