From 7f090c0cc68fd1915f835d6c8d1d6b23899ade03 Mon Sep 17 00:00:00 2001 From: nate Date: Sun, 11 May 2008 16:42:19 +0000 Subject: [PATCH] Fixing Socket test to run on non-standard virtual host configurations git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@6800 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/tests/cases/libs/socket.test.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cake/tests/cases/libs/socket.test.php b/cake/tests/cases/libs/socket.test.php index ccfbf5bd1..f1d03c02d 100644 --- a/cake/tests/cases/libs/socket.test.php +++ b/cake/tests/cases/libs/socket.test.php @@ -86,14 +86,14 @@ class SocketTest extends UnitTestCase { $this->Socket = new CakeSocket(); $this->Socket->connect(); $this->assertEqual($this->Socket->address(), '127.0.0.1'); - $this->assertPattern('/local/', $this->Socket->host()); + $this->assertEqual(gethostbyaddr('127.0.0.1'), $this->Socket->host()); $this->assertEqual($this->Socket->lastError(), null); $this->assertTrue(in_array('127.0.0.1', $this->Socket->addresses())); $this->Socket = new CakeSocket(array('host' => '127.0.0.1')); $this->Socket->connect(); $this->assertEqual($this->Socket->address(), '127.0.0.1'); - $this->assertPattern('/local/', $this->Socket->host()); + $this->assertEqual(gethostbyaddr('127.0.0.1'), $this->Socket->host()); $this->assertEqual($this->Socket->lastError(), null); $this->assertTrue(in_array('127.0.0.1', $this->Socket->addresses())); }