mirror of
https://github.com/pybind/pybind11.git
synced 2025-01-31 15:20:34 +00:00
style: pre-commit fixes
This commit is contained in:
parent
14d2dda5eb
commit
881b356ce8
@ -1049,7 +1049,8 @@ TEST_SUBMODULE(pytypes, m) {
|
|||||||
auto point = py::class_<Point>(m, "Point");
|
auto point = py::class_<Point>(m, "Point");
|
||||||
point.def(py::init());
|
point.def(py::init());
|
||||||
point.attr_with_type_hint<py::typing::ClassVar<float>>("x");
|
point.attr_with_type_hint<py::typing::ClassVar<float>>("x");
|
||||||
point.attr_with_type_hint<py::typing::ClassVar<py::typing::Dict<py::str, int>>>("dict_str_int") = py::dict();
|
point.attr_with_type_hint<py::typing::ClassVar<py::typing::Dict<py::str, int>>>("dict_str_int")
|
||||||
|
= py::dict();
|
||||||
|
|
||||||
m.attr_with_type_hint<py::typing::Final<int>>("CONST_INT") = 3;
|
m.attr_with_type_hint<py::typing::Final<int>>("CONST_INT") = 3;
|
||||||
m.attr("defined_PYBIND11_CPP17") = true;
|
m.attr("defined_PYBIND11_CPP17") = true;
|
||||||
|
@ -1143,7 +1143,6 @@ def test_class_attribute_types() -> None:
|
|||||||
assert m.Point().dict_str_int == {"hi": 3}
|
assert m.Point().dict_str_int == {"hi": 3}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@pytest.mark.skipif(
|
@pytest.mark.skipif(
|
||||||
not m.defined_PYBIND11_CPP17,
|
not m.defined_PYBIND11_CPP17,
|
||||||
reason="C++17 Position Independent Code not available",
|
reason="C++17 Position Independent Code not available",
|
||||||
|
Loading…
Reference in New Issue
Block a user