Skip to main content

Project Registration - Prototype Test

Manual test cases for the Project Registration workflow.


Workflow Overview

fill-in-project-info → fill-in-purchasing-info → review-purchasing-info

approved ← review-pre-work-procedures-form ← fill-in-pre-work-procedures-form

Test Case 1: Happy Path (Complete Flow)

Objective: Verify the complete workflow from creation to approval.

Phase 1: Create Task (Work Owner)

StepActionExpected Result
1Login as workownerLogin successful
2Click "+" button in toolbarTask type dialog opens
3Select "ลงทะเบียนโครงการ" (Project Registration)Task created, opens in review page
4Verify initial stateState: fill-in-project-info, form editable
5Verify toolbar buttonsShows "ส่งไปจัดซื้อ" and "ยกเลิกงาน"

Phase 2: Fill Project Info (Work Owner)

StepActionExpected Result
6Fill ชื่อโครงการ (Project Name)Field accepts input
7Select ผู้รับเหมา (Contractor) from dropdownContractor selected
8Fill วันที่เริ่มต้น/สิ้นสุด (Start/End dates)Dates set
9Click "ส่งไปจัดซื้อ" (Send to Purchasing)State changes to fill-in-purchasing-info

Phase 3: Fill Purchasing Info (Purchasing)

StepActionExpected Result
10Logout, login as purchasingLogin successful
11Open task from "My Tasks"Task opens
12Verify toolbarShows "ส่งกลับ" button
13Fill purchasing fields (PO Number, Budget)Fields accept input
14Click "ส่งกลับ" (Submit Back)State changes to review-purchasing-info

Phase 4: Review Purchasing (Work Owner)

StepActionExpected Result
15Logout, login as workownerLogin successful
16Open task from "My Tasks"Task opens
17Verify toolbar optionsShows: "ส่งไปจัดซื้อ", "ส่งไปผู้รับเหมา", "ยกเลิกงาน"
18Click "ส่งไปผู้รับเหมา" (Send to Contractor)State changes to fill-in-pre-work-procedures-form

Phase 5: Acknowledge Procedures (Contractor)

StepActionExpected Result
19Logout, login as contractor1Login successful
20Open task from "My Tasks"Task opens
21Verify documentsTwo docs: Project Registration (locked) + Pre-Work Procedures (editable)
22Verify toolbarShows "รับทราบระเบียบปฏิบัติงาน" button
23Fill acknowledgement checkboxesCheckboxes checked
24Click "รับทราบระเบียบปฏิบัติงาน"State changes to review-pre-work-procedures-form

Phase 6: Final Approval (Work Owner)

StepActionExpected Result
25Logout, login as workownerLogin successful
26Open task from "My Tasks"Task opens
27Verify toolbar optionsShows: "อนุมัติ", "ส่งไปจัดซื้อ", "ส่งไปผู้รับเหมา", "ยกเลิกงาน"
28Click "อนุมัติ" (Approve)State changes to approved
29Verify final stateTask is read-only, state shows "อนุมัติ"

Test Case 2: Cancel Early

Objective: Verify task can be cancelled from initial state.

StepActionExpected Result
1Login as workownerLogin successful
2Create new Project Registration taskTask created
3Click "ยกเลิกงาน" (Cancel)Confirmation dialog appears
4Confirm cancellationState changes to canceled
5Verify final stateTask is read-only

Test Case 3: Send Back for Revision

Objective: Verify Work Owner can send task back to Purchasing for corrections.

StepActionExpected Result
1-14Complete phases 1-3 (reach review-purchasing-info)At review state
15Click "ส่งไปจัดซื้อ" (Send back to Purchasing)State returns to fill-in-purchasing-info
16Login as purchasingLogin successful
17Make corrections, click "ส่งกลับ"State changes to review-purchasing-info

Test Case 4: State Visit Counts (Repetition Indicator)

Objective: Verify the stepper shows "(N)" badge when states are revisited.

StepActionExpected Result
1-14Complete phases 1-3 (reach review-purchasing-info)At review state
15Click "ส่งไปจัดซื้อ" (Send back to Purchasing)State returns to fill-in-purchasing-info
16Verify stepper"จัดซื้อ" step shows (2) badge
17Login as purchasing, submit againState changes to review-purchasing-info
18Verify stepper"รีวิวจัดซื้อ" step shows (2) badge
19Repeat steps 15-18Badges increment to (3), (3)

UI Verification Checklist

ComponentCheckExpected
Workflow TabTitleShows "ลงทะเบียนโครงการ"
Workflow TabStepperShows correct states for Project Registration
Workflow TabVisit CountShows "(N)" badge when state visited N > 1 times
SVG Diagram TabRenderDiagram renders correctly
SVG Diagram TabHighlightCurrent state is highlighted
ToolbarState LabelShows correct Thai text per state
ToolbarCommandsCorrect buttons per state
FormPermissionsCorrect lock/unlock per state
Document TabsVisibilityCorrect documents shown per state

State-Command Reference

StateCommands Available
fill-in-project-infoส่งไปจัดซื้อ, ยกเลิกงาน
fill-in-purchasing-infoส่งกลับ
review-purchasing-infoส่งไปจัดซื้อ, ส่งไปผู้รับเหมา, ยกเลิกงาน
fill-in-pre-work-procedures-formรับทราบระเบียบปฏิบัติงาน
review-pre-work-procedures-formอนุมัติ, ส่งไปจัดซื้อ, ส่งไปผู้รับเหมา, ยกเลิกงาน
approved(none - terminal)
canceled(none - terminal)

Sign-off

RoleNameDateSignature
Tester
Developer