blob: 20313332b986e5d5a930ec7dde0083a8a4094b6c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
<?php
/**
* Piwik - free/libre analytics platform
*
* @link http://piwik.org
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
*/
namespace Piwik\Tests\Fixtures;
use Piwik\Date;
use Piwik\Tests\Framework\Fixture;
/**
*
*/
class Utf8mb4 extends Fixture
{
public $idSite = 1;
public $dateTime = '2010-01-04 00:11:42';
public $trackInvalidRequests = true;
public function setUp()
{
$this->setUpWebsitesAndGoals();
$this->trackVisits();
}
public function tearDown()
{
// empty
}
private function setUpWebsitesAndGoals()
{
if (!self::siteCreated($idSite = 1)) {
self::createWebsite($this->dateTime);
}
}
private function trackVisits()
{
$t = self::getTracker($this->idSite, $this->dateTime, $defaultInit = true);
$t->setForceVisitDateTime(Date::factory($this->dateTime)->addHour(1)->getDatetime());
$t->setUrlReferrer('http://www.google.com/search?q=😡');
$t->setUrl('http://example.org/foo/🙙.html');
self::checkResponse($t->doTrackPageView('incredible 🚜'));
$t->addEcommerceItem('sku 🛸', 'name 🛩', 'category 🛤', 95);
self::checkResponse($t->doTrackEcommerceCartUpdate(100));
}
}
|