From 1a1ccabcd3253ffff5fa9180de073ee8c1756e7b Mon Sep 17 00:00:00 2001 From: Vyacheslav Agafonov Date: Fri, 2 Dec 2011 18:01:21 +0400 Subject: [PATCH] Use assertEquals() --- tests/form/FormTest.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tests/form/FormTest.php b/tests/form/FormTest.php index 9d988a1..6089b2d 100644 --- a/tests/form/FormTest.php +++ b/tests/form/FormTest.php @@ -27,11 +27,10 @@ class FormTest extends PHPUnit_Framework_TestCase $stub = $this->getMockForAbstractClass('Form'); $method = new ReflectionMethod('Form', 'addField'); $method->setAccessible(true); - $return_object = $method->invokeArgs($stub, array('login')); $this->assertInstanceOf('FormField', $return_object); - $this->assertSame($form_field, $return_object); + $this->assertEquals($form_field, $return_object); } public function testAddFieldWithMessage() @@ -41,10 +40,10 @@ class FormTest extends PHPUnit_Framework_TestCase $stub = $this->getMockForAbstractClass('Form'); $method = new ReflectionMethod('Form', 'addField'); $method->setAccessible(true); - $return_object = $method->invokeArgs($stub, array('login', $message)); + $this->assertInstanceOf('FormField', $return_object); - $this->assertSame($form_field, $return_object); + $this->assertEquals($form_field, $return_object); $this->assertAttributeEquals($message, 'default_message', $return_object); }