Skip to content

Commit

Permalink
make sure the UI tests run on all hosts
Browse files Browse the repository at this point in the history
  • Loading branch information
tsteur committed Jan 16, 2014
1 parent 4b10f39 commit 6a1cd04
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
Expand Up @@ -33,8 +33,10 @@ public function tearDown()

private function setUpWebsite()
{
$idSite = self::createWebsite($this->dateTime, $ecommerce = 1);
$this->assertTrue($idSite === $this->idSite);
if (!self::siteCreated($this->idSite)) {
$idSite = self::createWebsite($this->dateTime, $ecommerce = 1);
$this->assertSame($this->idSite, $idSite);
}
}

protected function trackFirstVisit()
Expand Down
Expand Up @@ -17,16 +17,19 @@ class Test_Piwik_Fixture_SomeVisitsCustomVariablesCampaignsNotHeuristics extends
public $dateTime = '2009-01-04 00:11:42';
public $idSite = 1;
public $idGoal = 1;
private $tmpHost = '';

public function setUp()
{
$this->tmpHost = $_SERVER['HTTP_HOST'];
$_SERVER['HTTP_HOST'] = 'localhost';

This comment has been minimized.

Copy link
@mattab

mattab Mar 3, 2014

Member

fyi I've reverted this change following feedback on piwik-hackers: http://lists.piwik.org/pipermail/piwik-hackers/2014-March/001463.html

$this->setUpWebsitesAndGoals();
$this->trackVisits();
}

public function tearDown()
{
// empty
$_SERVER['HTTP_HOST'] = $this->tmpHost;
}

private function setUpWebsitesAndGoals()
Expand Down

0 comments on commit 6a1cd04

Please sign in to comment.