Yêu cầu bài toán
Yêu cầu chức năng
Sơ đồ ca sử dụng
Các feature, scenario
Feature: Access home page
In order to prove that home page can access
As a non-login user
I want to test the home page for a phrase
Scenario: Root Test
When I go to homepage
Then I should see "PHPStorm"
Feature: Sign up
In order to participate into system
As a non-login user
I want to sign up into system
Scenario: Sign up test success to test admin
Given I am on "/"
When I fill in "sign-up-name" with "Admin Test"
And I fill in "sign-up-email" with "[email protected]"
And I fill in "sign-up-password" with "123456"
And I fill in "sign-up-password-confirm" with "123456"
And I press "signup"
And I should be on "/category"
Scenario: Sign up test success to test user
Given I am on "/"
When I fill in "sign-up-name" with "User Test"
And I fill in "sign-up-email" with "user\[email protected]"
And I fill in "sign-up-password" with "123456"
And I fill in "sign-up-password-confirm" with "123456"
And I press "signup"
Then I should be on "/category"
Scenario: Sign up test fail because of wrong email format
Given I am on "/"
When I fill in "sign-up-name" with "Admin Test"
And I fill in "sign-up-email" with "admin@gma"
And I fill in "sign-up-password" with "123456"
And I fill in "sign-up-password-confirm" with "123456"
And I press "signup"
Then I should be on "/"
And I should see "The email must be a valid email address"
Scenario: Sign up test fail because email has already taken
Given I am on "/"
When I fill in "sign-up-name" with "Admin Test"
And I fill in "sign-up-email" with "[email protected]"
And I fill in "sign-up-password" with "123456"
And I fill in "sign-up-password-confirm" with "123456"
And I press "signup"
Then I should be on "/"
And I should see "The email has already been taken"
Scenario: Sign up test fail because of wrong password confirmation
Given I am on "/"
When I fill in "sign-up-name" with "Admin Test"
And I fill in "sign-up-email" with "admin123@gmail"
And I fill in "sign-up-password" with "123456"
And I fill in "sign-up-password-confirm" with "654321"
And I press "signup"
Then I should be on "/"
And I should see "The password confirmation does not match"
Feature: Login
In order to participate in website
As a non-login person
I want to login into website
Scenario: Login Test success
Given I am on "/"
When I fill in "sign-in-email" with "[email protected]"
And I fill in "sign-in-password" with "123456"
And I press "login"
Then I should be on "/category"
Scenario: Login Test fail record
Given I am on "/"
When I fill in "sign-in-email" with "adsad"
And I fill in "sign-in-password" with "admin123"
And I press "login"
Then I should see "These credentials do not match our records."
- Feature: Access Question page from Category page
In order to see and answer question
As a login user
I want to access question from list
Scenario: Open question page
Given I am logged in as user ID 1
And I am on "/category"
When I follow "question"
Then I should be on "/category/1"
Feature: Access AddQuestion page from Category page
In order to prove that add question page can access
As a question maker or admin
I want to test that I can access add question page from category
Scenario: Access add question page
Given I am logged in as user ID 1
And I am on "/category"
When I follow "addQuestion"
Then I should be on "/addQuestion"
Feature: Access User page from Category page
In order to know name of people who participate website
As a user
I want to visit user page
Scenario: Access user
Given I am logged in as user ID 1
And I am on "/category"
When I follow "user"
Then I should be on "/user"
Feature: Manage user
In order to set decentralization for user
As a admin
I want to visit user page
Scenario: Set admin
Given I am logged in as user ID 1
And I am on "/user"
When I follow "admin-Admin Test"
Then I should be on "/user"
Scenario: Set question maker
Given I am logged in as user ID 1
And I am on "/user"
When I follow "questionaire-User Test"
Then I should be on "/user"
Scenario: Delete user
Given I am logged in as user ID 1
And I am on "/user"
When I follow "delete-User Test"
Then I should be on "/user"
And I should not see "User Test"
Feature: Add question
In order to have more and more question in systion
As a question maker or admin
I want to add a question into my system
Scenario: Access user
Given I am logged in as user ID 1
And I am on "/addQuestion"
When I fill in "id_type" with "1"
And I fill in "question_name" with "... is your surname?"
When I fill in "answer_A" with "What"
And I fill in "answer_B" with "Where"
And I fill in "answer_C" with "Who"
And I fill in "answer_D" with "When"
And I fill in "right_answer" with "A"
And I press "addSubmit"
And I go to "questionList/1"
Then I should see "... is your surname?"
Feature: Delete question
In order to remove question to the system
As a admin
I want to delete question from question list
Scenario: Delete question
Given I am logged in as user ID 1
And I am on "/questionList/1"
When I press "... is your surname"
Then I should be on "/questionList/1"
And I should not see ".our surname?"
Yêu cầu phi chức năng
Yêu cầu về hiệu năng
Thời gian load giữa các page là không quá 5 giây.
Thời gian xử lý kết nối tới các cơ sở dữ liệu không quá 2 giây.
Thời gian load của page mới tên miền phpstorm.esy.es (Số liệu được thống kê bằng công cụ kiểm thử GTMatrix)
Tính khả dụng, thiết kế giao diện người dùng
Người dùng sẽ có thể thao tác thành thào hệ thống trong 1 ngày sử dụng.
Đảm bảo tính dễ dùng, tối giản trang web đễ thiết kế các phần chính được hiển thị rõ hơn, khiễn người dùng vào không bị hoang mang.
Giao diện sáng, thiết kế theo tông màu xanh lá.
An toàn thông tin, bảo mật
Sử dụng csrf_token để tránh mạo danh người dùng (phòng tránh tấn công Cross-site request forgecy).
Phòng chống các câu lệnh sql injection cho hệ thống.
Ngăn không cho người dùng chèn các đoạn mã script vào hệ thống.
Duy trì, phân tích và mức độ khả chuyển
Đảm bảo hoạt động ổn định với 100GB bằng thông 1 tháng.
Sử dụng Google Analytic để phân tích website, lưu lượng và lượng truy cập.
Có thể sử dụng trên các trình duyệt tốt hiện nay như Google Chrome, Safari, Internet Explorer và một số loại trình duyệt khác.
Sử dụng được trên mobile.