/** * Test case for the Street property (Type: String, maxlength = 255, street * names cannot contain any special characters other than . or -). * The test creates a Person, setting its street from an array of fringe cases, * then checking whether there are validation errors and whether the retreived * street equals the set street. * @dataProvider streetProvider * @param multiple $street a value from the fringe cases array * @param integer $errorCount the expected amount of errors */ public function testStreet($street, $errorCount) { $this->markTestIncomplete("testing one property at the time"); try { $person = new Person(); $person->setStreet($street); $errors = $this->validator->validate($person); } catch (Exception $e) { //nothing needs to be done, this is mainly to sanitize output } $this->assertEquals($street, $person->getStreet()); $this->assertEquals($errorCount, count($errors)); }