Hello world!

This commit is contained in:
2020-07-22 12:54:04 +02:00
commit 868050bcbe
42 changed files with 3657 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
<?php
require __DIR__ . '/../src/UserAgentParser.php';
$time = microtime(true);
$uas = json_decode(file_get_contents(__DIR__ . '/../tests/user_agents.json'), true);
foreach( $uas as $ua => $junk ) {
$uatime = microtime(true);
for( $i = 0; $i <= 1000; $i++ ) {
\parse_user_agent($ua);
}
echo microtime(true) - $uatime;
echo " : $ua\n";
}
echo microtime(true) - $time;
echo " : TOTAL\n";