added better image test checking