Testing#
WIP
We have not yet figured out how to properly test code submissions. We need to get data into the notebooks and scripts. And the data must be small enough that the code runs quickly and within the memory bounds of GL. But we can’t spend all our time making small test files.
We would also like to simplify the mechanism to lower the entry barrier for new contributors. If you read this and have bright ideas, please contact the Scipp team!
The gist of the current mechanism for notebooks is:
- Add cells defining input parameters like filenames with placeholders: - filename = "INSERT-FILENAME" 
- After those, add cells that override the parameters with actual test parameters: - filename = dream.data.simulated_diamond_sample() - Tag these cells with - remove-cell.
- Add cells with - assertstatements to check the output of the code. Tag these cells with- remove-cell.
The remove-cell tag will ensure that the testing cells are not included in the deployed notebooks.
Users will only see the cells with placeholder parameters.