Test Driven Development Flashcards
1
Q
How can testing be performed?
A
Formal Methods to reason about correctness
Statistical analysis or simulation to investigate complex systems.
Random interaction with the system.
2
Q
Manual Testing?
A
Perform some task and check output
3
Q
Automated Testing
A
Automated tests are programmed to reduce effort.
4
Q
Define Refactoring
A
Change code that improves its structure but does not affect its behaviour.
5
Q
Give examples of bad coding practices.
A
- Duplicated Code
- Long Methods
- Poor Names (Make Parameter names descriptive!)
6
Q
JUnit features
A
- Setup method run and tear down method run after each execution of a test method.
7
Q
What does TDD provide?
A
- Simple easy to follow process
- Suite of automated tests that can check correctness of code after it is changed.
- Program unlikely to have redundant parts and that has been refactored.