Gain of power by a smart choice of goodness of fit test Suppose one would like to test that a sample of observations comes from Uniform(0,1) distribution. Instead of applying the Kolmogorov-Smirnov test on the sample, one may first apply the inverse CDF (quantile function) of $N(0,1)$ random variable and then apply a likelihood ratio (LR) test for $H_0\colon \mu=0,\sigma^2=1$ on these transformed observations. In finance, this idea dates back to Berkowitz "Testing Density Forecasts, With Applications to Risk Management" (2001) who refers back to Rosenblatt "Remarks on a Multivariate Transformation" (1952). Berkowitz suggests this trick allows us to gain power as LR test is uniformly most powerful (UMP).
I wonder where this power gain is coming from and at what expense (unless this is free lunch). And if this is free lunch, should we never use one-sample Kolmogorov-Smirnov test but always apply the transformation?

There is no free lunch. Berkowitz (2001) himself explains that the LR test is UMP w.r.t. a one-sided alternative such as $\mu<0,\sigma^2>1$. The power comes from going from a nonparametric to a parametric test. This entails assuming the shape of a normal curve for the transformed observations and then only examining the two moments, mean and variance. Thus it assumes away a number of violations of normality of the transformed data (uniformity of original data).
Consequently, it is not true that we should never use the Kolmogorov-Smirnov test on the original sample but always apply the transformation.
