public function test_generateCode() { $image_handler = new XoopsCaptchaImageHandler(); ob_start(); $image_handler->invalid = true; $x = $image_handler->generateCode(); $tmp = ob_end_clean(); $this->assertFalse($x); }