diff --git a/tests/cpp/wpiutil_test/module.cpp b/tests/cpp/wpiutil_test/module.cpp index 1e3f9fa..77f0a94 100644 --- a/tests/cpp/wpiutil_test/module.cpp +++ b/tests/cpp/wpiutil_test/module.cpp @@ -14,6 +14,8 @@ #include +struct Something{}; + /* array tests */ @@ -56,6 +58,9 @@ std::span load_span_fixed_double(std::span ref return ref; } +std::span load_span_const_object(std::span ref) { + return ref; +} std::span cast_span() { static std::vector vec{1, 2, 3}; @@ -151,6 +156,8 @@ RPYBUILD_PYBIND11_MODULE(m) { sendable_test(m); + py::class_(m, "Something"); + // array m.def("load_array_int", &load_array_int); m.def("load_array_int1", &load_array_int1); @@ -166,6 +173,7 @@ RPYBUILD_PYBIND11_MODULE(m) { m.def("cast_string_span", &cast_string_span); m.def("load_span_bytes", &load_span_bytes); m.def("modify_span_buffer", &modify_span_buffer); + m.def("load_span_const_object", &load_span_const_object); // SmallSet m.def("load_smallset_int", &load_smallset_int); m.def("cast_smallset", &cast_smallset);