Stubs yog siv nyob rau hauv Top-Down Integration Testing. Cov tsav tsheb tau siv hauv Kev Ntsuas Kev Sib Tw Hauv Qab.
Dab tsi yog hom kev xeem sib xyaw ua ke?
Qee yam sib txawv ntawm kev sib koom ua ke yog big-bang, sib xyaw (sandwich), pheej hmoo-hardest, saum-down, thiab hauv qab-upLwm yam kev koom ua ke yog: kev sib koom ua ke, kev koom ua ke qaum qaum, txheej kev sib koom ua ke, kev sib koom ua ke ntawm cov neeg siv khoom-neeg rau zaub mov, kev faib cov kev pabcuam sib koom ua ke thiab kev sib koom ua haujlwm siab.
Qhov twg ntawm cov tswv yim kev sim hauv qab no suav nrog kev siv cov stub thiab tsav tsheb rau kev sim?
Sandwich Testing yog kev sib xyaw ntawm txoj hauv qab-up thiab saum-down, yog li nws siv qhov zoo ntawm ob qho tib si hauv qab thiab sab saum toj mus kom ze. Thaum xub thawj nws siv cov stubs thiab tsav tsheb qhov twg stubs simulate tus cwj pwm ogf uas ploj lawm. Nws tseem hu ua Hybrid Integration Testing.
Dab tsi yog cov stubs hauv chav kuaj?
Ib tug stub yog ib qho me me ntawm txoj cai uas siv qhov chaw ntawm lwm cov khoom thaum kuaj. Qhov txiaj ntsig ntawm kev siv lub stub yog tias nws rov qab cov txiaj ntsig zoo ib yam, ua rau qhov kev sim sau yooj yim dua. Thiab koj tuaj yeem khiav kev sim txawm tias lwm cov khoom siv tseem tsis tau ua haujlwm.
Txoj haujlwm yog dab tsi?
Ib tug stub yog ib txoj haujlwm me me uas hloov pauv rau qhov kev pab cuam ntev dua, tejzaum nws yuav thauj khoom tom qab lossis qhov chaw nyob deb. Piv txwv li, ib qho kev pab cuam uas siv cov txheej txheem hu rau Chaw Taws Teeb (RPC) tau muab tso ua ke nrog cov stubs uas hloov rau qhov kev pab cuam uas muab cov txheej txheem thov.