The purpose of testing is to determine the correctness of the unit under test in some optimal way. One difficulty in meeting the optimality requirement is that the stochastic properties of the unit are usually unknown a priori; e. g. , the yield of a VLSI production line might not be known exactly before the chips made as a result are tested. Given the probability of unit failure and the coverage of a test, the optimal test period is easy to obtain. However, the probability of failure is not usually known a priori. The authors therefore develop an optimal sequential testing strategy which estimates the production yield based on ongoing test results, and then use it to determine the optimal test period.