Factory Management System Unit Test
Factory Management System Unit Test
Unit Test
Customer :
System Name :
Project Name :
Version :
Status :
System Released on :
Preserved in :
Created by :
Created on :
Last Revised by :
Last Revised on :
Copyright © 2013
IVS
Smart Factory
1.0
Copyright © 2013
System Name Factory Management System Function ID Approved By
Project Name Smart Factory Function Name Production Issue Approved On
Document Name Unit test Created By 12/30/1899 Revised By
Document ID Created On 30-12-1899 Revised On
Document History
Add
Approved By Note
Issue Approved On
Revised By
Revised On
ote
System Name Factory Management System Function ID 1st Tester Date
Project Name Smart Factory Function Name Production Issue 2nd Tester Date
Document Name Unit test Created By LPBTAN 3rd Tester Date
Document ID Created On 13/9/2024 Note
Result
No. Test Item Detail Fields / Reference / Remark Target
1st 2nd
1 Basic item
1.1 Source has been described following development's standard reference [[Link]] ○
1.2 Source comment has been described following development's standard reference [[Link]] ○
2 Screen layout
2.1 The screen title is correct? ○
2.2 The screen layout is same as design? ○
2.3 Image of buttons are correct (Delete, Save, Back, Update, ...)? ○
2.4 Message block has been displayed correctly? ○
2.5 Error messages are displayed correctly? ○
2.6 All control (button, label...) have been layout correctly in compare to design? ○
2.7 Have any omitted word, incorrected word in label or title of all control (button, label) ○
2.8 Text field is left aligned ○
2.9 Number, Currency field is right aligned ○
2.10 Date, Time field is right aligned ○
Currency = VND: #,###
2.11 Currency field is under "xxx,[Link]" format Currency = USD: #,### ○
Currency = JPY: #,###
2.12 Tab index has been set correctly? Left to right, up to down ○
2.13 Format of displayed date is correct? yyyy/mm/dd ○
2.14 When click Enter key, Submit action is created? ×
2.15 Password is displayed by "*" (asterisk) ×
2.16 Confirm Password is displayed by "*" (asterisk) ○
2.17 Mandatory fields has red "(*)" at the beginning of field ○
2.18 Menu (status, sub menu list) has been set correctly? ○
2.19 Status of all textbox has been set correctly? Editable/Readonly/Hidden ○
2.20 Status of all button has been set correctly? Enable/Disable/Invisible ○
2.21 Status of all compobox has been set correctly? Editable/Readonly/Hidden ○
3 Search/List Screen
3.1 Number of displayed records is correct? ×
3.2 Are the input value in search condition re-displayed? ×
3.3 If search result has data, number of records is correct ×
3.4 If search result has more than 100 row, do system show error message correctly and exit event? ×
3.5 Sort order are correct. ×
3.6 Group by default is correct? ×
3.7 Group by options are correct? ×
3.8 The result grid can be sorted by clicking the header titles. ×
3.9 Width of columns can resize manually. ×
3.10 Height of rows (include Header row) can not resize manually ×
4 Input/DetailSQL
Preventing Screen
injection attacks
4.1 When sql keyword is inputted, is displayed correctly? Input value is displayed as the original inp ○
4.2 Ex: " ' "; "--",contains
Combobox "' ; DROP table
value M_XXXX;"
correctly? ○
4.3 In controls to input character, is maxlength correctly set? = size of database field ○
4.4 Message type is suitable? "Error", "Warning", "Information", … ○
5 Authority
5.1 User, that do not have right to Add New in this function, can't register new data ○
5.2 User, that do not have right to Modify in this function, can't modify data ○
5.3 User, that do not have right to Delete in this function, can't delete data ○
5.4 User, that do not have right to View in this function, can't open the function ○
5.5 Menu list is correct with role of logined user? ○
6 Export function ( Export to file, print Document)
6.1 Output filename is correct with design? ○
6.2 Output data is correct ○
6.3 8.3.1 Output 0 record ○
6.4 8.3.1 Output 1 record ○
6.5 8.3.1 Output many records ○
6.6 Output order is correct ○
6.7 Format of output file is as the same as the template file ○
6.8 Edited data is not saved to the database ○
7 Common function
7.1 In case at least 1 field is modified, a confirmation message (save or not save) is shown ○
7.2 When insert/update/delete data, a confirmation message is shown ○
7.3 There is a message to indicate saved data correctly ○
7.4 Can save data correctly with mandatory fields input only ○
7.5 Can save data correctly with every fields input ○
7.6 On screen input data and DB data is matched ○
7.7 Saved data is displayed correctly ○
7.8 revised_id, deleted_id are correct ○
7.9 revised_date, deleted_date are correct ○
7.10 Is event log created correct? Insert into table TBL_LOG ○
7.11 When show/insert/update data, had been trimmed? Check each field ○
8 Additonal case: Maxlength
8.1 Operating Unit 50 ○
8.2 Warehouse 50 ○
8.3 Document Type 50 ○
8.4 Document No 50 ○
8.5 Created By 50 ○
8.6 Created Date 50 ○
8.7 Document Date 50 ○
8.8 Issued By 50 ○
8.9 Status 50 ○
8.10 Description 150 ○
8.11 No. (Grid View) ○
8.12 Instruction No (Grid View) ○
8.13 Operation (Grid View) ○
8.14 Item Code (Grid View) ○
8.15 Item Name (Grid View) ○
8.16 Unit (Grid View) ○
8.17 Quality Status (Grid View) ○
8.18 Quantity (Grid View) ○
8.19 Lot No (Grid View) ○
8.20 Location (Grid View) ○
8.21 Production Date (Grid View) ○
8.22 Remark (Grid View) ○
9 Additonal case: Control displays all characters when input full text
9.1 Operating Unit displays all characters ○
9.2 Warehouse displays all characters ○
9.3 Document Type displays all characters ○
9.4 Document No displays all characters ○
9.5 Created By displays all characters ○
9.6 Created Date displays all characters ○
9.7 Document Date displays all characters ○
9.8 Issued By displays all characters ○
9.9 Status displays all characters ○
9.10 Description displays all characters ○
9.11 No. (Grid View) displays all characters ○
9.12 Instruction No (Grid View) displays all characters ○
9.13 Operation (Grid View) displays all characters ○
9.14 Item Code (Grid View) displays all characters ○
9.15 Item Name (Grid View) displays all characters ○
9.16 Unit (Grid View) displays all characters ○
9.17 Quality Status (Grid View) displays all characters ○
9.18 Quantity (Grid View) displays all characters ○
9.19 Lot No (Grid View) displays all characters ○
9.20 Location (Grid View) displays all characters ○
9.21 Production Date (Grid View) displays all characters ○
9.22 Remark (Grid View) displays all characters ○
10 Additonal case: Format of displayed is correct?
10.1 Operating Unit char ○
10.2 Warehouse char ○
10.3 Document Type char ○
10.4 Document No char ○
10.5 Created By char ○
10.6 Created Date datetime ○
10.7 Document Date datetime ○
10.8 Issued By char ○
10.9 Status char ○
10.10 Description char ○
10.11 No. (Grid View) number ○
10.12 Instruction No (Grid View) char ○
10.13 Operation (Grid View) char ○
10.14 Item Code (Grid View) char ○
10.15 Item Name (Grid View) char ○
10.16 Unit (Grid View) char ○
10.17 Quality Status (Grid View) char ○
10.18 Quantity (Grid View) char ○
10.19 Lot No (Grid View) char ○
10.20 Location (Grid View) char ○
10.21 Production Date (Grid View) number ○
10.22 Remark (Grid View) char ○
11 Additonal case: When input full text, the string is saved to DB correctly
11.1 Operating Unit ○
11.2 Warehouse ○
11.3 Document Type ○
11.4 Document No ○
11.5 Created By ○
11.6 Created Date ○
11.7 Document Date ○
11.8 Issued By ○
11.9 Status ○
11.10 Description ○
11.11 No. (Grid View) ○
11.12 Instruction No (Grid View) ○
11.13 Operation (Grid View) ○
11.14 Item Code (Grid View) ○
11.15 Item Name (Grid View) ○
11.16 Unit (Grid View) ○
11.17 Quality Status (Grid View) ○
11.18 Quantity (Grid View) ○
11.19 Lot No (Grid View) ○
11.20 Location (Grid View) ○
11.21 Production Date (Grid View) ○
11.22 Remark (Grid View) ○
12 Additonal case: Alignment
12.1 Operating Unit Left ○
12.2 Warehouse Left ○
12.3 Document Type Left ○
12.4 Document No Left ○
12.5 Created By Left ○
12.6 Created Date Center ○
12.7 Document Date Center ○
12.8 Issued By Left ○
12.9 Status Left ○
12.10 Description Left ○
12.11 No. (Grid View) Center ○
12.12 Instruction No (Grid View) Center ○
12.13 Operation (Grid View) Left ○
12.14 Item Code (Grid View) Left ○
12.15 Item Name (Grid View) Left ○
12.16 Unit (Grid View) Left ○
12.17 Quality Status (Grid View) Left ○
12.18 Quantity (Grid View) Left ○
12.19 Lot No (Grid View) Left ○
12.20 Location (Grid View) Left ○
12.21 Production Date (Grid View) Center ○
12.22 Remark (Grid View) Left ○
Result 0/159
Result 0/159
Result 0/159
Result
Note
2nd 3rd
UTP_outline-01
Mode = Edit
1.2
Mode = Allocated
Go to [Get Item]
3 Get Items 3.1
screen
8 Close
8 Close Show confirm
Don't save 8.2
Change value message
Save Update successfully 8.3
General Header
○ ○
○ ○
○ ○
○ 1 2 3 5 6
○ ○
○ ○
○ ○
○ ○
○ ○
○ ○
○ ○
○ ○
○ ○ ○
○ ○ ○ ○
○ ○ ○ ○ ○
○ ○ ○ ○ ○ ○
○ ○ ○ ○ ○ ○
○ ○
○ ○
○ ○
○ ○
○ ○
○ ○ ○
○ ○ ○ ○
○ ○ ○ ○ ○
○ ○ ○ ○ ○ ○
○ ○ ○ ○ ○ ○
○ ○
○ ○
○ ○
○ ○
○ ○
System Name Factory Management SystemFunction ID 1st Tester Date
Project Name Smart Factory Function Name Production Issue 2nd Tester Date
Document Name Unit test Created By LPBTAN 3rd Tester Date
Document ID Created On 13/9/2024 Note
2 Tab Index
- Click Manage Stock > Transaction Management >
1. Prepare a user account with full Transaction Issue > Production Issue When you press [Tab] on keyboard. Control will be
right on [Production Issue] screen focused on [Warehouse] then you press [Tab] on the
2.1 ○
2. Prepare data as sheet [DataTest- keyboard the focused control will move form left to right,
Prerequisite-01] top to bottom
3 Get Items
- Click Manage Stock > Transaction Management >
1. Prepare a user account with full Transaction Issue > Production Issue
right on [Production Issue] screen - Click [Get item] button
-Show popup message: " [Warehouse] must be filled in!" ○
2. Prepare data as sheet [DataTest-
Prerequisite-01]
4 Clear
- Click Manage Stock > Transaction Management >
1. Prepare a user account with full Transaction Issue > Production Issue
right on [Production Issue] screen - Click [Clear] button
4.1 All fields are empty. ○
2. Prepare data as sheet [DataTest-
Prerequisite-01]
5 Save
- Click Manage Stock > Transaction Management >
Transaction Issue > Production Issue
- Click [Save] button 1. Show message:
1. Prepare a user account with full
[Warehouse] must be filled in!
right on [Production Issue] screen
5.1 [Status] must be filled in! ○
2. Prepare data as sheet [DataTest-
[Issue By] must be filled in!
Prerequisite-01]
Transaction list must be filled in!
7 Export
1. Click Manage Stock > Transaction Management >
Transaction Overview
1. Prepare a user account with full
2. [Transaction Type] = "Production Issue"
right on [Production Issue] screen
7.1 3. Click [Search] button Show [Export] screen ○
2. Prepare data as sheet [DataTest-
4. Double click row with [Document No] = "DN001"
Prerequisite-01]
5. Click [Export] button
8 Close
1. Click Manage Stock > Transaction Management >
1. Prepare a user account with full Transaction Issue > Production Issue -> Search
right on [Production Issue] screen 2. Click [Search] button
8.1 3. Double click row with [Document No] = "DN001" Close the form ○
2. Prepare data as sheet [DataTest-
Prerequisite-01] 4. Click [Close] button
5. Click [Yes] 1. The system show message "The information changes.
1. Click Manage Stock > Transaction Management > Do you want to save before exit?"
Transaction Issue > Production Issue -> Search 2. The system show message "Data has been
2. Click [Search] button successfully updated."
8.2 Continue above case 3. Double click row with [Document No] = "DN001" ○
3. Result as sheet [Expected Data-01] No.1
4. Change values: 4. [Production Issue] screen is closed
+ [Remark] = "Nguyen Van A" + Reload Girdview, the selected data row is updated on
4.
1. Click
Click [Close]
Managebutton
Stock > Transaction Management > gird
Transaction Issue > Production Issue -> Search
2. Click [Search] button
3. Double click row with [Document No] = "DN001"
4. Change values: Show a message: "Do you want to save?"
8.3 Continue above case + [Remark] = "Nguyen Van A" ○
+ The system will be closed and don't save any value.
4. Click [Close] button
5. Click [Yes]
Result 0/26
Result 0/26
Result 0/26
Evidence Note
1 General
General Header
Warehouse (*) Document Date (*) Issued By (*) Status (*) Description
Production Warehou 13/09/2024 IVS01 Allocated
1 General
General Header
Issued By
Warehouse (*) Document Date (*) Status (*) Description
(*)
Production Warehouse 13/09/2024 IVS01 Allocated
System Name Factory Management System Function ID
Project Name IWMS Function Name Production Issue
Document Name Unit test Created By LPBTAN
Document ID Created On 9/13/2024
Result
No. Test Item Detail Fields / Reference / Remark Target
1st 2nd
1 Basic item
1.1 Source has been described following development's standard reference [[Link]] ○
1.2 Source comment has been described following development's standard reference [[Link]] ○
2 Screen layout
2.1 The screen title is correct? ○
2.2 The screen layout is same as design? ○
2.3 Image of buttons are correct (Delete, Save, Back, Update, ...)? ○
2.4 Message block has been displayed correctly? ○
2.5 Error messages are displayed correctly? ○
2.6 All control (button, label...) have been layout correctly in compare to design? ○
2.7 Have any omitted word, incorrected word in label or title of all control (button, label) ○
2.8 Text field is left aligned ○
2.9 Number, Currency field is right aligned ○
2.10 Date, Time field is right aligned ○
Currency = VND: #,###
2.11 Currency field is under "xxx,[Link]" format Currency = USD: #,### ○
Currency = JPY: #,###
2.12 Tab index has been set correctly? Left to right, up to down ○
2.13 Format of displayed date is correct? yyyy/mm/dd ○
2.14 When click Enter key, Submit action is created? ×
2.15 Password is displayed by "*" (asterisk) ×
2.16 Confirm Password is displayed by "*" (asterisk) ×
2.17 Mandatory fields has red "(*)" at the beginning of field ×
2.18 Menu (status, sub menu list) has been set correctly? ○
2.19 Status of all textbox has been set correctly? Editable/Readonly/Hidden ○
2.20 Status of all button has been set correctly? Enable/Disable/Invisible ○
2.21 Status of all compobox has been set correctly? Editable/Readonly/Hidden ○
3 Search/List Screen
3.4 If search result has more than 100 row, do system show error message correctly and exit event? ×
ult
Note
3rd
Data is existed in
database Search by input fileds
3 Search
0 row
4 Push
n row
5 Close
Summary
Instruction No Operation BOM Code Item Code Item Name BOM Quantity BOM Unit
1 2 3 4 9 10
Issue Quantity Issue Unit
11 12
System Name Factory Management System Function ID 1st Tester Date
Project Name IWMS Function Name Production Issue 2nd Tester Date
Document Name Unit test Created By 12/30/1899 3rd Tester Date
Document ID Created On 12/30/1899 Note
Result
No. Pre-Requisites Test Screen Expected result Target Evidence
1st 2nd 3rd
1 Load
Click Manage Stock > Transaction
1. Prepare a user account without right Management > Transaction Issue >
on [Production Issue] screen Get Items Production Issue -> Get Items
1.1 You cannot access to [Production Issue] screen Get Items ○
2. Prepare data as sheet [DataTest-
Prerequisite-02]
2 Tab Index
Click Manage Stock > Transaction
1. Prepare a user account with full right Management > Transaction Issue >
on [Production Issue] screen Get Items Production Issue -> Get Items When you press [Tab] on keyboard. Control will be focused
2.1 ○
2. Prepare data as sheet [DataTest- status from left to right and from top to bottom
Prerequisite-02]
3 Search
Click Manage Stock > Transaction
1. Prepare a user account with full right Management > Transaction Issue >
on [Production Issue] screen Get Items Production Issue -> Get Items - Show a message box "1 row(s) found!"
3.1 Click [Search] button or press [Enter] key ○
2. Prepare data as sheet [DataTest- - The result is as sheet [Expected Data-02] No.1.
Prerequisite-02]
Note