Skip to main content

Flea

Flea helps you test WSGI applications without starting up an HTTP server.

If you already know lxml, you’ll know what makes flea so powerful. Flea is fully integrated with lxml’s xpath api, letting you inspect, modify and navigate HTML documents returned from your WSGI application. Here’s an example session:

>>> agent = TestAgent(my_wsgi_app)
>>> agent.get('/')
>>> print agent.body
<html>
        <body>
                <a href="/sign-in">sign in</a>
        </body>
</html>
>>> agent = agent["//a[.='sign in']"].click()
>>> print agent.request.request_uri
http://localhost/sign-in
>>> agent["//input[@name='username']"].value = 'root'
>>> agent["//input[@name='password']"].value = 'password'
>>> agent = agent["//input[@type='submit']"].submit()

Full package documentation: http://packages.python.org/flea/

Metadata

Release files for flea 3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flea 3
File Size Uploaded Provenance Actions
flea-3.tar.gz 16.7 kB Without provenance Details for flea-3.tar.gz

Release files / flea-3.tar.gz

Download URL flea-3.tar.gz
Size 16.7 kB
Tags Source
SHA-256 checksum
How to use checksums
3802e0d80b13a57a77616fce7a64384b7047a0bef5f156aed8206c823e744f84
BLAKE2b-256 checksum
How to use checksums
ee8a9790a34e92f1fb23c59ae93e0920cea30229b34e1e61f8db7f4f8c81782e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for flea 3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

3 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page