Skip to content

Commit

Permalink
test: add escape bracket.
Browse files Browse the repository at this point in the history
Signed-off-by: ytetsuro <[email protected]>
  • Loading branch information
ytetsuro committed Sep 14, 2018
1 parent 3e632c3 commit b3527da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/system/Validation/ValidationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -550,8 +550,8 @@ public function testSplitRegex()
{
$method = $this->getPrivateMethodInvoker($this->validation, 'splitRules');

$result = $method('required|regex_match[/^[0-9]{4}[\-\.\/][0-9]{2}[\-\.\/][0-9]{2}/]|max_length[10]');
$result = $method('required|regex_match[/^[0-9]{4}[\-\.\[\/][0-9]{2}[\-\.\[\/][0-9]{2}/]|max_length[10]');

$this->assertEquals('regex_match[/^[0-9]{4}[\-\.\/][0-9]{2}[\-\.\/][0-9]{2}/]', $result[1]);
$this->assertEquals('regex_match[/^[0-9]{4}[\-\.\[\/][0-9]{2}[\-\.\[\/][0-9]{2}/]', $result[1]);
}
}

0 comments on commit b3527da

Please sign in to comment.