Closed orbeckst closed 6 years ago
I started adding some unit tests. There is one small one to check dx files 8467c7bc9068.
It would be nice to know if this files covers all the information we potentially want to extract from a dx file.
TODO:
Thanks @kain88-de for all the work you've been putting into updating the package. You should be able to write to the repo now. For bigger changes, do a feature branch/PR and assign to someone else like @richardjgowers or myself for review. By all means, ping me if nothing seems to be moving forward.
For the tests we need small example files. I should be able to get a small plt file with gridcount but I have no ccp4 one, maybe @holocronweaver has one?
Sure, I can make one for testing. Do you have a particular 3D data set you want to fill it with?
On 11 Sep, 2015, at 14:21, Jesse Johnson wrote:
Sure, I can make one for testing. Do you have a particular 3D data set you want to fill it with?
I don't have one at hand. The smaller the better so that we can include it as test data.
@holocronweaver have a look at the dx test file. Something like this is enough. It should be small and contain all meta-data you find important.
For the data I choose to have 8 points (2 in every direction) each with a value of 1. That is enough to see if the reading works.
On 11 Sep, 2015, at 14:46, kain88-de wrote:
@holocronweaver have a look at the dx test file. Something like this is enough. It should be as small and contain all meta-data you find important.
For the data I choose to have 8 points (2 in every direction) each with a value of 1. That is enough to see if the reading works.
Actually, less symmetry is better, something like 2 x 3 x 5 because this can help with catching errors of swapping axes.
Here is a test CCP4 file: https://app.box.com/s/d3l9boh11x7q0bjtskskj003v09uw92z It is 8 x 4 x 6 and the grid points have values equal to their column-major index in a 1D array. Hope it is sufficient for unit testing. (BTW, creating this file uncovered a major bug in my software! Good thing it hasn't been released to the public yet. Sometimes contributing to OSS has unexpected benefits.)
Not sure why I didn't close this one. We have had CI with tests for a long time...
We should have some minimal unit tests for the package. They could be part of the package and wouldn't have to be separate. Look to use cStringIO to use tiny inline fixtures.