Пример #1
0
 /**
  * Constructs a new test case.
  * 
  * @param boolean $isExample whether this test case is an example
  * @param array $inputs the inputs for this test case
  * @param mixed $expectedOutput the expected output
  * @param string $explanation optional explanation of the expected output
  */
 public function __construct($isExample, $inputs, $expectedOutput, $explanation = '')
 {
     parent::__construct('test case');
     Validator::validateBoolean($isExample, 'is example');
     Validator::validateArray($inputs, 'inputs');
     Validator::validateNotNull($expectedOutput, 'expected output');
     Validator::validateString($explanation, 'explanation', true);
     $this->isExample = $isExample;
     $this->inputs = $inputs;
     $this->expectedOutput = $expectedOutput;
     $this->explanation = $explanation;
 }