quamash
quamash copied to clipboard
"In the face of ambiguity refuse the temptation to guess" -- Tim Peters
the dependency injection stuff. This branch is quite a bit cleaner than the depinject branch (I made a depinject4realz branch and then started over again with a depinject5realz branch)
So I'm asking for comments/review of this code to see if it seems to hackish or a suitably elegant solution befitting a pull request with a Zen of Python quote as it's title.
see #16
I made a few comments in the diff. The hack of using the module attribute of the application type is quite nice, as long as it works with all (supported) Qt wrappers. I would maybe factor that out into a separate function (this is quite some magic happening where you would not expect it and it is not immediately obvious what and why this is happening; a function would allow for a matching docstring), but this is just personal taste.
Note that the failing appveyor tests (kinda) pass. py.test is returning an exit status that isn't zero, but the console output shows all tests pass. I'm able to replicate this on my end, so it's probably something that can be fixed, but I'm not entirely sure it's a problem with qumash or a problem with py.test.