views:

43

answers:

3

Like I want to check

on Every page <h3> tag must come after <h2> otherwise page should be marked.

like if any page has PDF then Some particular text <p>Download Adobe reader from here</p> should be at bottom of every page is this condition is not matched then page should be marked.

I want to make different type of conditions to check then want to check on whole site and if anything mismatch then report should be generated.

+1  A: 

Do you necessarily have to use XHTML? I'd use Python and BeautifulSoup, myself.

(Edit: I was confused - I was thinking of XSLT, not XHTML, and I thought "why would you use XSLT for someting like this?". XHTML is fine, and my recommendation of Python and BeautifulSoup still stands.)

Teddy
yes because site are based on xhtml css
metal-gear-solid
can u give some more info how can i make and run test ?
metal-gear-solid
A: 

This ruby gem looks like it could be useful to you:

http://code.google.com/p/opticon/

I haven't personally used it, but it claims to basically do what you're asking for.

samg
but it's only for linux
metal-gear-solid
A: 

I've had, and still have, the same need on many of my projects. In my case I'm looking for anything with the class 'error'. This is supported by the TestPlan product in it's verification engine.

In my case, as a quick example, I have several "Web" states and my generic verify script is:

CheckNot //div[@class='error']

Now the way TestPlan works is that every state within "Web" will first run this generic verify script.

If you're interested I could help you come up with the exact syntax needed to do your check.

edA-qa mort-ora-y