Refactor debt test