From 2d14c1c5db04d4d09cb62196f64cfb87908075af Mon Sep 17 00:00:00 2001 From: Jason Rhinelander Date: Sat, 15 Apr 2017 11:12:41 -0400 Subject: [PATCH] Fixed bad_arg_def imports Don't try to define these in the issues submodule, because that fails if testing without issues compiled in (e.g. using cmake -DPYBIND11_TEST_OVERRIDE=test_methods_and_attributes.cpp). --- tests/test_methods_and_attributes.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_methods_and_attributes.cpp b/tests/test_methods_and_attributes.cpp index 9b52b9915..8ce25b64a 100644 --- a/tests/test_methods_and_attributes.cpp +++ b/tests/test_methods_and_attributes.cpp @@ -299,11 +299,11 @@ test_initializer methods_and_attributes([](py::module &m) { m.attr("debug_enabled") = false; #endif m.def("bad_arg_def_named", []{ - auto m = py::module::import("pybind11_tests.issues"); + auto m = py::module::import("pybind11_tests"); m.def("should_fail", [](int, NotRegistered) {}, py::arg(), py::arg("a") = NotRegistered()); }); m.def("bad_arg_def_unnamed", []{ - auto m = py::module::import("pybind11_tests.issues"); + auto m = py::module::import("pybind11_tests"); m.def("should_fail", [](int, NotRegistered) {}, py::arg(), py::arg() = NotRegistered()); }); });