Tests for segfaults in python bindings