Aiming at the problem that uncertainty risk loss is lacking of considering in testability demonstration test, a method for testability demonstration test based on cost optimization is proposed. In the method cost of fault injection, risk cost of producer and consumer is synthetically considered, and a model based on test cost is established. On the basis of binomial distribution theory, the calculation method of producers risk and consumers risk is provided, and the variation tendency of producers risk and consumers risk changing along with the test plan is analyzed. On this basis, optimization solving method of test cost model is presented under the principle of minimize the posterior expected cost. At last, an example is given to show the validity of the proposed method.