After a preliminary study of equivalence classes, the teacher raised a new question
is still a editbox problem, adding 3 text boxes, how the division of equivalence classes will change
the title should read as follows :
Allow 1 to 6 English characters or numbers, press OK to end
Valid equivalence classes:
Length: 1 to 6
Character: a-z,a-z,0-9
Invalid equivalence class
Length: 0,7
Characters: English/numeric characters, control characters, punctuation
There are three text boxes
The design is as follows:
Partitioning equivalence classes with input criteria
Condition one length between 1 to 6
Condition two characters belong to A-z,a-z,0-9
|
Number |
Valid equivalence classes |
Number |
Invalid equivalence class |
|
1 |
1 to 6 numbers |
5 |
Less than 1 digits |
|
2 |
Characters belong to A-Z |
6 |
Greater than 6 digits |
|
3 |
Characters belong to A-Z |
7 |
Character contains control characters |
|
4 |
4 |
Character belongs to 0-9 |
8 |
Characters contain punctuation |
9 |
Three text boxes with correct input |
10 |
There is a text box with incorrect input |
|
|
|
|
|
|
|
|
Test cases for equivalence class partitioning
Number |
Case |
overriding equivalence classes |
Expected output |
1 |
Az0912 Az0912 Az0912 |
1,2,3,9 |
Right |
2 |
Az0912 Az0912 az0912a |
2,3,6,10 |
Wrong |
3 |
Az0912 Az0912 Null character |
5,10 |
Wrong |
4 |
Az0912 Az0912 Az091, |
1,2,3,8,10 |
Wrong |
5 |
Az0912 Az0912 DEL91, |
1,2,3,8,7,10 |
Wrong |
6 |
Az0912 Az0912 DEL910 |
1,2,3,7,10 |
Wrong |
7 |
Az0912 Az0912 111111 |
1,4,10 |
Right |
8 |
Az0912 Az0912 Aaaaaa |
1,2,10 |
Right |
9 |
Az0912 Az0912 Aaaaaa |
1,3,10 |
Right |
Experience
1, when the program becomes complex, it is obvious that software testing will become more complex. So in the programmer code, should also take into account the testing personnel encountered problems, software personnel testing should also consider the difficulty of the programmer to delete and modify.
2, the change of equivalence class division also caused the change of the test case, the more complicated design also increased the workload of the test, the test case is not complete, should each text box to control the remaining two text box under the conditions of the last lesson in the test.
3, software testing should indeed be in the process of software development, or it will increase the workload of developers and testers
Software testing: Equivalence class partitioning-----editbox problems adding text boxes