add a function check_all() and put some documentation