Skip to content

Commit

Permalink
Build was failing again. Result of getHostByAddr
Browse files Browse the repository at this point in the history
depends on /etc/hosts. On most systems ::1 will resolve
to ipv6-localhost, but for Travis it resolves to localhost.

refs #2622
  • Loading branch information
halfdan committed Feb 8, 2013
1 parent 32e25b8 commit 97de0ab
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/PHPUnit/Core/IPTest.php
Expand Up @@ -691,7 +691,7 @@ public function testGetHostByAddr()

if (!Piwik_Common::isWindows() || PHP_VERSION >= '5.3')
{
$hosts = array( 'ip6-localhost', strtolower(@php_uname('n')), '::1' );
$hosts = array( 'ip6-localhost', 'localhost', strtolower(@php_uname('n')), '::1' );
$this->assertTrue( in_array(strtolower(Piwik_IP::getHostByAddr('::1')), $hosts), '::1 -> ip6-localhost' );
}
}
Expand Down

0 comments on commit 97de0ab

Please sign in to comment.