Skip to content

Commit

Permalink
Added a more relaxed assertation
Browse files Browse the repository at this point in the history
  • Loading branch information
CloCkWeRX committed Nov 29, 2011
1 parent 20fa601 commit e3e2243
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions tests/XML_Feed_Parser_TestCase.php
Expand Up @@ -24,5 +24,14 @@ function setup() {
$this->fp_test_dir);
}
}

/**
* The python tests expect lowercase strings like 'rss20'
* Our (stable) API returns strings like "RSS 2.0"
*/
protected function assertVersionMostlyCorrect($expected, $actual, $message = '') {
$mostly_actual = str_replace(array(" ","."), "", strtolower($actual));
$this->assertEquals($expected, $mostly_actual, $message);
}
}
?>

0 comments on commit e3e2243

Please sign in to comment.