Added math.Vector2 subclass test for issue #552 #560
Wouldn't it be desirable to test this in a child process? The way it is now the test doesn't really fail, but instead the process just terminates with only the message "Segmentation fault (core dumped)"
Edit: It doesn't look all that nice, but at least on my system this works (relies on OS returning nonzero for segmentation faulting processes but every one I've used so far does that):
I only recently did my first contribution here, so I'm not really good at writing good looking / maintainable code and I'd appreciate someone else rewriting this as i think it looks pretty horrible :/
Hello @Nunu-Willump . Thanks for that.
Yeah, testing code which uses C extensions like pygame makes it a bit harder to test things than normal python code which crashes nicely. The test runner has an option run each test in a separate process. Since there is already a fix lined up for this issue, I think it's fine in this instance to avoid adding the subprocess code in as you've done. You can use subprocesses in the test runner with
-Added the expectedFailure decorator over testVector2Subclass() -added space inbetween the arguements of v = Vector and self.assertEqual for code beautification