Peter Heisig
Software consultant and developer from Dresden.
Softwaretechnologie I / Übung IV
slides.com/phdd/st1e4/live
Akzeptanztests
Integrationstests
Systemtests
Unittests
C1
C1
C2
C1
C2
...
Cn
C1
C2
...
Cn
Testfallbestimmung
White-Box Tests
Black-Box Tests
stochastische Verfahren
Ablaufgraph-überdeckung
Datenfluss-analyse
...
Äquivalenz-klassenanalyse
Grenzwert-analyse
...
|
||||
---|---|---|---|---|
L1 | Exception | Leibeigener | -1 | Einkommen darf nicht negativ sein |
L2 | ok | Leibeigener | 0 | 1 |
L3 | ok | Leibeigener | 12 | 1 |
L4 | ok | Leibeigener | 22 | 1 |
L5 | ok | Leibeigener | 253 | 24 |
Testfall | Erwarteter Status | Klasse | Eingabe (Einkommen) | Ausgabe (Steuer) |
---|---|---|---|---|
|
||||
Feature | JUnit 3.x | JUnit 4.x |
---|---|---|
test annotation | testXXX pattern | @Test |
run before the first test method in the current class is invoked | None | @BeforeClass |
run after all the test methods in the current class have been run | None | @AfterClass |
run before each test method | override setUp() | @Before |
run after each test method | override tearDown() | @After |
ignore test | Comment out or remove code | @ignore |
expected exception | catch exception assert success | @Test(expected = ArithmeticException.class) |
timeout | None | @Test(timeout = 1000) |
asjava.com/junit/junit-3-vs-junit-4-comparison
pehei.de
slides.com/phdd
twitter.com/_phdd
By Peter Heisig