(ctx: Context)
| 269 | |
| 270 | |
| 271 | def test_core_sync(ctx: Context): |
| 272 | # Use the field from the parsed schema so it has the @expectedType AST node. |
| 273 | foo_type = _EXPECTED_TYPE_SCHEMA.type_map["Foo"] |
| 274 | sync_field = foo_type.fields["sync"] |
| 275 | handler = _ObjectField( |
| 276 | ctx, |
| 277 | "sync", |
| 278 | sync_field, |
| 279 | foo_type, |
| 280 | ) |
| 281 | |
| 282 | assert handler.func_signature() == "async def sync(self) -> Self:" |
| 283 | |
| 284 | assert str(handler.func_body()).endswith( |
| 285 | 'return await self._ctx.execute_sync(self, "sync", _args)' |
| 286 | ) |
| 287 | |
| 288 | |
| 289 | def test_generate_modern_id_surface(): |
nothing calls this directly
no test coverage detected