Foliensatz 5
Foliensatz 5
Foliensatz 5
Sie wollen auch ein ePaper? Erhöhen Sie die Reichweite Ihrer Titel.
YUMPU macht aus Druck-PDFs automatisch weboptimierte ePaper, die Google liebt.
of. G. Kemnitz · Institut für Informatik, Technische Universität Clausthal 13. Juli 2012 22/96<br />
1. Software 2. Testauswahl mit Äquivalenzklassen<br />
x y Beispiel Testauswahl für x<br />
0 ≤ x < 1 y := x 0, 0.5, 0.999<br />
1 ≤ x < 3 y := (x − 2) 2 1, 1.5, 2, 2.7, 2.98<br />
3 ≤ x ≤ 4 y := 3 − x 3, 3,2, 4<br />
sonst Fehlermeldung -100, -0.1, 4.01, 345<br />
Testrahmen mit Testeingaben:<br />
type tRealArray is array (natural range ) of real;<br />
constant xVektor: tRealArray := (0.0, 0.5, ..., 345.0);<br />
variable x, y: real;<br />
...<br />
for idx in xVector’range loop<br />
x := xVector(idx);<br />
y := f(x);<br />
write("x=" & str(x) & " y=" & str(y));<br />
end loop;<br />
Die Testausgaben sind hier manuell zu kontrollieren.