FIX Hardcode the year to the current year in setUp()

This commit is contained in:
Michael Strong 2015-11-09 15:52:21 +13:00
parent a27dd892f6
commit 930074c2a2

View File

@ -110,7 +110,7 @@ class BlogTest extends SapphireTest {
$link = Controller::join_links($blog->Link('archive')); $link = Controller::join_links($blog->Link('archive'));
$this->assertEquals(200, $this->getStatusOf($link), 'HTTP Status should be 200'); $this->assertEquals(200, $this->getStatusOf($link), 'HTTP Status should be 200');
$this->assertEquals(SS_Datetime::now()->Year(), ModelAsController::controller_for($blog)->getArchiveYear(), 'Defaults to current year'); $this->assertEquals('2013', ModelAsController::controller_for($blog)->getArchiveYear(), 'Defaults to current year');
$link = Controller::join_links($blog->Link('archive'), 'invalid-year'); $link = Controller::join_links($blog->Link('archive'), 'invalid-year');