Add py and pytest to requirements.
Add validate_list_option() to check if a command line option is an item in a list.