(self, string, value=None)
| 269 | return cls.X |
| 270 | |
| 271 | def safe_exec(self, string, value=None): |
| 272 | d = {} |
| 273 | try: |
| 274 | exec(string, globals(), d) |
| 275 | except Exception as e: |
| 276 | if value: |
| 277 | self.fail( |
| 278 | "Could not exec %r (from value %r): %s" % (string.strip(), value, e) |
| 279 | ) |
| 280 | else: |
| 281 | self.fail("Could not exec %r: %s" % (string.strip(), e)) |
| 282 | return d |
| 283 | |
| 284 | def serialize_round_trip(self, value): |
| 285 | string, imports = MigrationWriter.serialize(value) |
no outgoing calls
no test coverage detected