(self)
| 6028 | ) |
| 6029 | |
| 6030 | def test_noparent(self): |
| 6031 | Item, User = self.classes.Item, self.classes.User |
| 6032 | |
| 6033 | sess = fixture_session() |
| 6034 | q = sess.query(User) |
| 6035 | |
| 6036 | u1 = q.filter_by(name="jack").one() |
| 6037 | |
| 6038 | # TODO: this can perhaps raise an error, then again it's doing what's |
| 6039 | # asked... |
| 6040 | q = sess.query(Item).filter(with_parent(u1, User.orders)) |
| 6041 | self.assert_compile( |
| 6042 | q, |
| 6043 | "SELECT items.id AS items_id, " |
| 6044 | "items.description AS items_description " |
| 6045 | "FROM items, orders WHERE :param_1 = orders.user_id", |
| 6046 | ) |
| 6047 | |
| 6048 | def test_m2m(self): |
| 6049 | Item, Keyword = self.classes.Item, self.classes.Keyword |
nothing calls this directly
no test coverage detected