/** * Tests the thenReturn functionality of the proxy. * * It should result in the binder being called with a static answer. * * @todo we need argument capturing so I can make sure the answer matches. */ public function testThenReturn() { $this->binder->expects($this->once())->method('bindAnswer')->with($this->logicalAnd($this->isInstanceOf('Phake_Stubber_Answers_StaticAnswer'), $this->attributeEqualTo('answer', 42)))->will($this->returnValue($this->binder)); $this->assertSame($this->binder, $this->proxy->thenReturn(42)); }