The Kolmogorov–Smirnov test seems pretty straightforward, but the devil is in the details, as they say. If you have the cumulative distribution function (CDF) available (you didn't say which distribution you're dealing with), you just sort your data values and compare them with the CDF.