(self, tbl, name, *wanted)
| 198 | c.arg("context") |
| 199 | |
| 200 | def _check_default_slots(self, tbl, name, *wanted): |
| 201 | slots = [ |
| 202 | "default", |
| 203 | "onupdate", |
| 204 | "server_default", |
| 205 | "server_onupdate", |
| 206 | ] |
| 207 | col = tbl.c[name] |
| 208 | for slot in wanted: |
| 209 | slots.remove(slot) |
| 210 | assert getattr(col, slot) is not None, getattr(col, slot) |
| 211 | for slot in slots: |
| 212 | assert getattr(col, slot) is None, getattr(col, slot) |
| 213 | |
| 214 | def test_py_vs_server_default_detection_one(self): |
| 215 | has_ = self._check_default_slots |