Fixed unused variable in test method

The startpoint variable wasn't used when calculating the endpoint.