add more checking before testing page