[TIP] Testing HTML using CSS selectors
Terry Peppers
peppers at gmail.com
Thu Mar 1 07:03:34 PST 2007
On 3/1/07, Simon Willison <simon at simonwillison.net> wrote:
> Running assertions against an HTML document using CSS selectors was
> just too good an idea to miss, so I've put together a simple extension
> to BeautifulSoup that allows you to do exactly that:
>
> http://code.google.com/p/soupselect/
Simon -
Excellent idea. When I have some time, this might make an excellent
Twill extension to compose. "Time" obviously being the key term.
Still, this is something that would make it easier to extract certain
elements of a page and determining their validity - especially if
they're in a specific DIV.
For Titus:
What version of BeautifulSoup is Twill using? - I swear awhile back I
got all crossed up because I was using BS 3.0 terminology and I think
Twill comes with an older version (maybe 2.0).
More information about the testing-in-python
mailing list