Add tests - and fix an obvious sliding bug tests exhibited