Describe the bug
There are multiple validation failures while creating tests.
The test can be give negative marks
Duration can be negative (rolls over when processed by backend)
Answer provided in MCQ questions doesn't need to be one of the options (see bitfield in Multiple Select and Numerical Answer Type Questions + (Dynamic #choices) #82 for a solution)
Number of questions can be negative
Total marks and number of questions required in the generated test aren't validated with the number of questions in the question bank
To Reproduce
Steps to reproduce the behavior:
Create a new test
Give it negative marks (-100)
Give it negative duration (0 hours, -20 mins) (-ve hours gives a warning)
Add question, all 4 options need to be selected
Add negative no. of questions and negative marks
Press next after verifying
Check the dashboard (local build on latest master branch)
Expected behavior
Error message should be shown whenever a validation fails. And the next button blocked until the mistakes are corrected.
Desktop (please complete the following information):
OS: ArchLinux
Browser firefox
Version 86.0
Describe the bug
There are multiple validation failures while creating tests.
To Reproduce
Steps to reproduce the behavior:
Create a new test
Give it negative marks (-100)
Give it negative duration (0 hours, -20 mins) (-ve hours gives a warning)

Add question, all 4 options need to be selected

Add negative no. of questions and negative marks

Press next after verifying

Check the dashboard (local build on latest master branch)

Expected behavior
Error message should be shown whenever a validation fails. And the next button blocked until the mistakes are corrected.
Desktop (please complete the following information):