move tests closer to the code they are testing