implemented testXY