move unused code to src/test