3 class PHPT_Case_Validator_Runnable
implements PHPT_Case_Validator
5 private $_message = false;
7 public function __construct()
12 public function validate(PHPT_Case
$case)
14 if (!$this->is($case)) {
15 throw new PHPT_Case_InvalidCaseException($this->_message
);
19 public function is(PHPT_Case
$case)
21 if ($case->sections
->has('FILE') == false) {
22 $this->_message
= 'missing FILE section';
23 } elseif ($case->sections
->has('TEST') == false) {
24 $this->_message
= 'missing TEST section';
27 return !(bool)$this->_message
;