MCPcopy Create free account
hub / github.com/webpy/webpy / test_limit_with_unsafe_value

Method test_limit_with_unsafe_value

tests/test_db.py:232–243  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

230 super().tearDown()
231
232 def test_limit_with_unsafe_value(self):
233 db = self.db
234 db.insert("person", False, name="Foo")
235 assert len(db.select("person").list()) == 1
236
237 try:
238 db.select("person", limit="1; DELETE FROM person;")
239 except db.db_module.Error:
240 # It is alright if the db engine rejects this query
241 pass
242
243 assert len(db.select("person").list()) == 1
244
245 def test_offset_with_unsafe_value(self):
246 db = self.db

Callers

nothing calls this directly

Calls 3

insertMethod · 0.80
listMethod · 0.80
selectMethod · 0.80

Tested by

no test coverage detected