Skip to content

Commit

Permalink
Unit tests MDL-24992 Fixed mod/wiki unit test CRLF issue (ahem, not u…
Browse files Browse the repository at this point in the history
…sing ereg)
  • Loading branch information
sammarshallou committed Nov 1, 2010
1 parent cf72c96 commit 49a874c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mod/wiki/simpletest/testwikiparser.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ private function assertTestFile($num, $markup) {
$result = wiki_parser_proxy::parse($input, $markup, array('pretty_print' => true));

//removes line breaks to avoid line break encoding causing tests to fail.
$result['parsed_text'] = ereg_replace("[\r\n]", '', $result['parsed_text']);
$output = ereg_replace("[\r\n]", '', $output);
$result['parsed_text'] = preg_replace('~[\r\n]~', '', $result['parsed_text']);
$output = preg_replace('~[\r\n]~', '', $output);

$this->assertEqual($result['parsed_text'], $output);
return true;
Expand Down

0 comments on commit 49a874c

Please sign in to comment.