Skip to content

Commit

Permalink
Test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
goktugcy committed Jun 29, 2024
1 parent e84cfb9 commit 28d6776
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/DetectorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class DetectorTest extends TestCase
{
// protected function setUp(): void
// {

// }

public function testGetUserBrowser()
Expand Down Expand Up @@ -59,9 +59,10 @@ public function testGetUserInfo()
{
$_SERVER['HTTP_USER_AGENT'] = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.3';
$_SERVER['HTTP_ACCEPT_LANGUAGE'] = 'en-US,en;q=0.9,fr;q=0.8';
$_SERVER['REMOTE_ADDR'] = '123.123.123.123';

$userInfo = Detector::getUserInfo();
$expected = 'Google Chrome | Windows 10 | PC | English';
$expected = 'Google Chrome | Windows 10 | PC | English | 123.123.123.123';

$this->assertEquals($expected, $userInfo);
echo $userInfo . "\n";
Expand Down

0 comments on commit 28d6776

Please sign in to comment.