To test a multiple-choice form with randomly generated responses to simulate the actions of real users.
Use ScenarioBuilder’s “Switch” and “Case” actions to simulate real-user responses. Build a case for each response. For the example below, we’ll build cases to randomly answer in a variety of ways;
This is an interesting example because we want to simulate users providing different answers, and in some cases,multiple answers.
1. Create a CSV file containing a row with a value to represent each differentIn this example we’ll create 6 responses, so our CSV file will contain 6 rows containing numbers 1 through 6.
2. Open ScenarioBuilder and attach the CSV file to a newSet the “Variable Access Property” to “Random”;
3. Add a “Switch” action to theIn the “Variable Name” property field, enter the name of the variable (case sensitive) that was created in the CSV file. Frame the value with percentage signs;
4. Add six “Case” actions to theFor cases one through five, add a “Click On Image” action for each of the five choices on the survey. For case six, add two “Click On Image” actions to test the form’s capacity to handle more than one box being checked;
Note: For the “Click On Image” actions capture enough of each answer to make each image unique;
Case 1 (Children over 8 years old):
Case 2 (Children under 8 years old):
Also note: The “Anchor Position X” property on the “Click on Image” actions is set to “left” to ensure that the mouse click lands on the check-box on the form;