From 7d18cda7eed7d94f46f3a24e3066d589d6423b85 Mon Sep 17 00:00:00 2001 From: Sam Minnee Date: Fri, 28 Oct 2016 17:45:01 +1300 Subject: [PATCH] FIX: Test fixes needed for the new simplified test run structure. --- tests/controller/SilverStripeNavigatorTest.php | 2 +- tests/model/RedirectorPageTest.php | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/controller/SilverStripeNavigatorTest.php b/tests/controller/SilverStripeNavigatorTest.php index add3cf03..d2946a7d 100644 --- a/tests/controller/SilverStripeNavigatorTest.php +++ b/tests/controller/SilverStripeNavigatorTest.php @@ -15,7 +15,7 @@ use SilverStripe\Dev\TestOnly; class SilverStripeNavigatorTest extends SapphireTest { - protected static $fixture_file = 'cms/tests/controller/CMSMainTest.yml'; + protected static $fixture_file = 'CMSMainTest.yml'; public function testGetItems() { $page = $this->objFromFixture('Page', 'page1'); diff --git a/tests/model/RedirectorPageTest.php b/tests/model/RedirectorPageTest.php index 75b7780a..707d09fd 100644 --- a/tests/model/RedirectorPageTest.php +++ b/tests/model/RedirectorPageTest.php @@ -13,6 +13,12 @@ class RedirectorPageTest extends FunctionalTest { protected static $use_draft_site = true; protected $autoFollowRedirection = false; + public function setUp() + { + parent::setUp(); + Director::config()->update('alternate_base_url', 'http://www.mysite.com/'); + } + public function testGoodRedirectors() { /* For good redirectors, the final destination URL will be returned */ $this->assertEquals("http://www.google.com", $this->objFromFixture('SilverStripe\\CMS\\Model\\RedirectorPage','goodexternal')->Link());