MDL-48002 inbound: Update regex for token matching

This commit is contained in:
Ankit Agarwal 2015-05-04 13:51:19 +05:30
parent bf06f672f4
commit 7f9b8cf3a3

View File

@ -103,7 +103,7 @@ class core_messageinbound_testcase extends advanced_testcase {
protected function read_test_file(\SplFileInfo $file, $fixturesdir) {
// Break on the --[TOKEN]-- tags in the file.
$tokens = preg_split('#(?:^|\n*)----([A-Z-]+)----\n#', file_get_contents($file->getRealPath()),
$tokens = preg_split('#(?:^|\n*)----([A-Z]+)----\n#', file_get_contents($file->getRealPath()),
null, PREG_SPLIT_DELIM_CAPTURE);
$sections = array(
// Key => Required.