Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_fn(self):
"Example from `PyQuery.Fn` docs."
fn = lambda: this.map(lambda i, el: pq(this).outerHtml()) # NOQA
pq.fn.listOuterHtml = fn
S = pq(self.html)
self.assertEqual(S('li').listOuterHtml(),
['<li>Coffee</li>', '<li>Tea</li>', '<li>Milk</li>'])