Chapter 6: Validation Flashcards
Validation techniques
- Length check
- Range check
- Presence check
- Format check
Length check
Process of ensuring that input data is not too short or too long
Range check
Process of ensuring that input data is within the required range of values
Presence check
Process of ensuring that all required inputs are provided
Format check
Process or ensuring that input data matches a required arrangement or pattern
Types of program error
- Syntax errors
- Run-time errors
- Logic errors
Syntax errors
Errors that are due to incorrect source code that does not follow the rules of the language
Run-time errors
Errors that are detected while the program is running, usually causing the program to crash or hang
Logic errors
Errors that usually do not cause the program to crash or hang immediately;instead the program does not give the expected output
Conditions for test cases
- Normal conditions
- Boundary conditions
- Error conditions
Bug
Deflect in a program that causes it to behave in an unintended manner
Debugging
Process of identifying and removing deflects from a program
Debugging techniques
- Using intermittent print statements
2. Testing the program in chunks or parts