2.3 Flashcards
What is validation?
The checking of data on input to ensure that it is sensible
What is a range check?
Checks that a number/date is in the allowed range
What is a type check?
Checks that the data is the right type- integer/character/string
What is a length check?
Checks that the text entered isn’t too long or too short
What is a presence check?
Checks that data has been entered
What is a format check?
Checks that the format is appropriate- postcode, email address, etc
What is verification?
The input of data twice- If they match, the entry is accepted as valid
What is authentication?
A process used to test that a person is who they claim to be- e.g biometrics
What are some considerations in defensive design?
anticipating misuse/ authentication
What is the point of indentation?
aids readability and is mandatory in some programming languages
What is the point of commenting?
to help ensure the program can be understood and maintained long after it was written
What is the purpose of testing?
To ensure that for any input, the program always works correctly
What is iterative testing?
finding and correcting errors in the program until all tests give the expected results. This is done during development
What is final/terminal testing?
Carried out by users after the program is completely finished.
What should test data include?
normal data, boundary data, invalid data, erroneous data
What is boundary data?
data that includes both ends of an allowed range and data just outside the range which shouldn’t be allowed
What is invalid data?
Data outside the limits of valid data
What is erroneous data?
Completely wrong data- like a number when it is meant to be a word
What do refining algorithms do?
Make programs more efficient- for example, ending the program when there have been no swaps in a single pass reduces the execution time, as there are no unnecessary passes after the list is already sorted