Download plugins/Bandwidth/tests/Unit/MetricsTest.php from Leon4gr45/matomo: direct link, hf CLI and curl.
- Browser
- Download file 1.27 kB
-
https://huggingface.co/spaces/Leon4gr45/matomo/resolve/main/plugins/Bandwidth/tests/Unit/MetricsTest.php
- Command line
-
hf download hf://spaces/Leon4gr45/matomo/plugins/Bandwidth/tests/Unit/MetricsTest.php
-
curl -L -o MetricsTest.php https://huggingface.co/spaces/Leon4gr45/matomo/resolve/main/plugins/Bandwidth/tests/Unit/MetricsTest.php
1.27 kB
| /** | |
| * Matomo - free/libre analytics platform | |
| * | |
| * @link https://matomo.org | |
| * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later | |
| */ | |
| namespace Piwik\Plugins\Bandwidth\tests\Unit; | |
| use Piwik\Plugins\Bandwidth\Metrics; | |
| use Piwik\Tests\Framework\TestCase\UnitTestCase; | |
| /** | |
| * @group Bandwidth | |
| * @group MetricsTest | |
| * @group Plugins | |
| */ | |
| class MetricsTest extends UnitTestCase | |
| { | |
| public function test_getMetricTranslations() | |
| { | |
| $translations = Metrics::getMetricTranslations(); | |
| $expected = [ | |
| 'nb_hits_with_bandwidth' => 'Bandwidth_ColumnHitsWithBandwidth', | |
| 'max_bandwidth' => 'Bandwidth_ColumnMaxBandwidth', | |
| 'min_bandwidth' => 'Bandwidth_ColumnMinBandwidth', | |
| 'sum_bandwidth' => 'Bandwidth_ColumnSumBandwidth', | |
| 'avg_bandwidth' => 'Bandwidth_ColumnAvgBandwidth', | |
| 'nb_total_overall_bandwidth' => 'Bandwidth_ColumnTotalOverallBandwidth', | |
| 'nb_total_pageview_bandwidth' => 'Bandwidth_ColumnTotalPageviewBandwidth', | |
| 'nb_total_download_bandwidth' => 'Bandwidth_ColumnTotalDownloadBandwidth', | |
| ]; | |
| $this->assertEquals($expected, $translations); | |
| } | |
| } | |