You must use selenium to test Javascript interaction. Maybe you only need to test the endpoints where the combo data comes from.
Sep 17, 2015
4
Level 3
Phpunit how to test a form having dependency between dropdowns
Hi, I'm trying to use phpunit in my app (I'm learning how to use it)... Now I have the next question... How I can complete a form having 2 dropdowns, when the second dropdown only is completed if the first one is chose (using ajax and json). e.g. first I completed the dropdown called Country (when you selected a value then it will complete the other dropdown which is City). So right now if I used:
->select('1', 'country_id')
->select('5', 'county_id')
doesn't work... Phpunit is telling me that the value 5 of "county_id" is not a possible value. After that said that the possible values are "" (so i guess is never completing the second dropdown using phpunit).
Thanks! =)
Please or to participate in this conversation.