  A large class of goodness-of-fit test statistics based on sup-functionals of
weighted empirical processes is proposed and studied. The weight functions
employed are Erd\H{o}s-Feller-Kolmogorov-Petrovski upper-class functions of a
Brownian bridge. Based on the result of M. Cs\"{o}rg\H{o}, S. Cs\"{o}rg\H{o},
Horv\'{a}th, and Mason obtained for this type of test statistics, we provide
the asymptotic null distribution theory for the class of tests in hand, and
present an algorithm for tabulating the limit distribution functions under the
null hypothesis. A new family of nonparametric confidence bands is constructed
for the true distribution function and it is found to perform very well. The
results obtained, together with a new result on the convergence in distribution
of the higher criticism statistic, introduced by Donoho and Jin, demonstrate
the advantage of our approach over a common approach that utilizes a family of
regularly varying weight functions. Furthermore, we show that, in various
subtle problems of detecting sparse heterogeneous mixtures, the proposed test
statistics achieve the detection boundary found by Ingster and, when
distinguishing between the null and alternative hypotheses, perform optimally
adaptively to unknown sparsity and size of the non-null effects.
