Black box tests for algorithmic stability