Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Revert "Make test a bit more solid."

This reverts commit 072991d.
  • Loading branch information...
commit 21a51a374a9ef8e1cd8bf7f890e1e25b279016bb 1 parent 072991d
@markstory markstory authored
Showing with 2 additions and 9 deletions.
  1. +2 −9 lib/Cake/Test/Case/Network/CakeSocketTest.php
View
11 lib/Cake/Test/Case/Network/CakeSocketTest.php
@@ -179,18 +179,11 @@ public function testTimeOutConnection() {
$config = array('host' => '127.0.0.1', 'timeout' => 0.5);
$this->Socket = new CakeSocket($config);
$this->assertTrue($this->Socket->connect());
- }
-/**
- * test timing out raises exception
- *
- * @expectedException SocketException
- * @expectedExceptionMessage Operation timed out
- */
- public function testTimeOutThrowException() {
$config = array('host' => '127.0.0.1', 'timeout' => 0.00001);
$this->Socket = new CakeSocket($config);
- $this->Socket->read(1024 * 1024);
+ $this->assertFalse($this->Socket->read(1024 * 1024));
+ $this->assertEquals('2: ' . __d('cake_dev', 'Connection timed out'), $this->Socket->lastError());
}
/**
Please sign in to comment.
Something went wrong with that request. Please try again.