setUpWebsitesAndGoals(); $this->trackVisits(); } public function tearDown() { // empty } private function setUpWebsitesAndGoals() { self::createWebsite($this->dateTime); } private function trackVisits() { $dateTime = $this->dateTime; $idSite = $this->idSite; $t = self::getTracker($idSite, $dateTime, $defaultInit = true, $useThirdPartyCookie = 1); $t->setUrlReferrer('http://www.google.com/search?q=piwik'); $t->setUrl('http://example.org/foo/bar.html'); self::checkResponse($t->doTrackPageView('http://incredible.title/')); $t->setUrl('https://example.org/foo/bar.html'); $t->setForceVisitDateTime(Date::factory($dateTime)->addHour(0.2)->getDatetime()); self::checkResponse($t->doTrackPageView('https://incredible.title/')); $t->setUrl('https://wWw.example.org/foo/bar2.html'); $t->setForceVisitDateTime(Date::factory($dateTime)->addHour(0.3)->getDatetime()); self::checkResponse($t->doTrackPageView('http://www.incredible.title/')); $t->setUrl('http://WwW.example.org/foo/bar2.html'); $t->setForceVisitDateTime(Date::factory($dateTime)->addHour(0.4)->getDatetime()); self::checkResponse($t->doTrackPageView('https://www.incredible.title/')); $t->setUrl('http://www.example.org/foo/bar3.html'); $t->setForceVisitDateTime(Date::factory($dateTime)->addHour(0.5)->getDatetime()); self::checkResponse($t->doTrackPageView('incredible.title/')); $t->setUrl('https://example.org/foo/bar4.html'); $t->setForceVisitDateTime(Date::factory($dateTime)->addHour(0.6)->getDatetime()); self::checkResponse($t->doTrackPageView('incredible.title/')); } }