(num_init_args, smart_ptr)
| 40 | ], |
| 41 | ) |
| 42 | def test_with_alias_invalid(num_init_args, smart_ptr): |
| 43 | class PyDrvdWithAlias(m.with_alias): |
| 44 | pass |
| 45 | |
| 46 | with pytest.raises(TypeError) as excinfo: |
| 47 | PyDrvdWithAlias(*((0,) * num_init_args)) |
| 48 | assert ( |
| 49 | str(excinfo.value) |
| 50 | == "pybind11::init(): construction failed: returned " |
| 51 | + smart_ptr |
| 52 | + " pointee is not an alias instance" |
| 53 | ) |
nothing calls this directly
no test coverage detected