# A school admin can invite teacher, teacher can invite student and parent using invite code

## Description:
Admin can invite teacher, teacher can invite student and parent using invite code.

## Step-by-step procedure:

### A) Admin add new class
1. Launch the application.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on "+ Class" button.
13. On "Add class" screen, click on Save button.
14. Verify that user getting error saying Class name field is a required field.
15. Click on "Class name" field and enter the class name.
16. Click on "Description" field and enter the class description.
17. Click on the Save button.
18. Verify user is in newly added class detail screen.

### B) Admin sending invite code to the teacher

1. Admin user on class detail screen clicks on "+ Add Teacher" button.
2. Verify user is in "Add teacher" screen.
3. Admin click on "Copy invite code" button and copy the code.
4. Admin send this code to teacher user via a messaging app (eg: Whatsapp)

### C) Teacher sign-up via invite code to the class

1. Teacher launch the application on their device.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Click on "I have an invite code" button.
8. Verify user is in "Enter invite code" screen.
9. User clicks on "Next" button.
10. Verify user is getting error saying "Enter an invite code"
11. Click on "Invite code" field and enter an invalid code.
12. User clicks on "Next" button.
13. Verify user is getting an error, sayin "Invalid code, try again".
14. Click on "Invite code" field and enter valid code shared by admin.
15. User clicks on "Next" button.
16. Verify user is in "Invitation" screen also verify the class name.
17. Click on "Next" button.
18. Verify user on "Terms and conditions" screen.
19. Click on "Accept" button.
20. User is in "Your profile" screen.
21. User clicks on "Next" button.
22. Verify the user getting error saying Your name, gender and date of birth fields are mandatory.
23. User enter name, select gender and enter date of birth
24. User clicks on "Next" button.
25. User is in "Create account" screen.
26. Verify username is generated automatically.
27. Clicks on "Next" button.
28. Clicks on "Sig-up" button on Create account screen.
29. Verify user gets error saying "Password" is required.
30. User enter password and clicks on "Sign-up" button.
31. Verify user is in "Waiting for approval" screen.


### D) Admin approve teacher's request to join the class

1. Launch the application.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see pending request list.
14. Verify user able to see teacher name in the list
15. Click on "Approve" button.
16. Verify user able to see the Teacher name under teacher's list.

### E) Teacher login to the class

1. Launch the app again
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see members list.
14. Verify user able to see their name under Teacher's list.
15. Teacher user on class detail screen clicks on "+ Add Student" button.
16. Verify user is in "Add student" screen.
17. Teacher click on "Copy invite code" button and copy the code.
18. Teacher send this code to student user via a messaging app (eg: Whatsapp)

### G) Student sign-up via invite code to the class

1. Student launch the application on their device.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Click on "I have an invite code" button.
8. Verify user is in "Enter invite code" screen.
9. Click on "Invite code" field and enter valid code shared by admin.
10. User clicks on "Next" button.
11. Verify user is in "Invitation" screen also verify the class name.
12. Click on "I'm a Student" button.
13. User is in "Your profile" screen.
14. User enter name, select gender and enter date of birth
15. User clicks on "Next" button.
16. User is in "Create account" screen.
17. Verify username is generated automatically.
18. Clicks on "Next" button.
19. User enter password and clicks on "Sign-up" button.
20. Verify user is in "Waiting for approval" screen.


### H) Teacher approve student's request to join the class

1. Launch the application.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see pending request list.
14. Verify user able to see student's name in the list
15. Click on "Approve" button.
16. Verify user able to see the Student name under Student's list.

### I) Student login to the class

1. Launch the app again
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see members list.
14. Verify user able to see their name under Student's list.

### J) Parent sign-up their child to the class using invite code

1. Parent user launch the application on their device.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Click on "I have an invite code" button.
8. Verify user is in "Enter invite code" screen.
9. Click on "Invite code" field and enter valid code shared by admin.
10. User clicks on "Next" button.
11. Verify user is in "Invitation" screen also verify the class name.
12. Click on "I'm a Parent" button.
13. Verify user is in "Terms and conditions" screen.
14. Click on "Accept" button.
15. User is in "Your profile" screen.
16. User enter parent's name, select gender and enter date of birth
17. User clicks on "Next" button.
18. User is in "Create account" screen.
19. Verify username is generated automatically.
20. Clicks on "Next" button.
21. User enter password and clicks on "Sign-up" button.
22. Verify user is in "Child profile" screen.
23. User enter Child's name, select gender and enter date of birth
24. User clicks on "Done" button.
25. Verify user is in "Waiting for approval" screen.

### K) Teacher approve student's request to join the class

1. Launch the application.
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the username.
8. Tap on the **Password** field and enter the password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see pending request list.
14. Verify user able to see student's name (Child user) in the list
15. Click on "Approve" button.
16. Verify user able to see the Student name under Student's list.

### L) Parent login to the class

1. Launch the app again
2. Click **Get started** button on On-boarding screen.
3. On "Let's get started" screen, Tap on the **School name** field.
4. Enter the **School name**.
5. Select on School name that will appear below the School name field.
6. Verify the user is in **Login** screen.
7. Tap on the **Username** field and enter the parent's username.
8. Tap on the **Password** field and enter the parent's password.
9. Tap on the **Login** button.
10. Verify the user is in the **Apps** screen.
11. Click on the "Classes" tab.
12. Click on class name
13. On class detail screen verify user able to see members list.
14. Verify user able to see their child's name under Student's list.