mirror of https://gitlab.com/cppit/jucipp
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
466 B
26 lines
466 B
|
7 years ago
|
#include "python_type_casters.h"
|
||
|
|
#include <test_suite.h>
|
||
|
|
|
||
|
|
int main() {
|
||
|
|
{
|
||
|
7 years ago
|
suite test_suite("PythonModule_tests");
|
||
|
7 years ago
|
{
|
||
|
7 years ago
|
py::module::import("python_module_test");
|
||
|
7 years ago
|
test_suite.has_assertion = true;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
{
|
||
|
7 years ago
|
suite test_suite("PythonModule_tests");
|
||
|
7 years ago
|
{
|
||
|
|
try {
|
||
|
|
py::module::import("exception_test");
|
||
|
|
}
|
||
|
|
catch(const py::error_already_set &error) {
|
||
|
|
test_suite.has_assertion = true;
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
return 0;
|
||
|
|
}
|