forked from LiveCarta/PayPal-PHP-SDK
Removed Deprecated Getter and Setters
- Removed Deprecated Getter Setters from all Model Classes - All Camelcase getters and setters are removed. Please use first letter uppercase syntax - E.g. instead of using get_notify_url(), use getNotifyUrl() instead
This commit is contained in:
@@ -55,36 +55,6 @@ class FlowConfigTest extends \PHPUnit_Framework_TestCase
|
||||
$this->assertEquals($obj->getBankTxnPendingUrl(), "http://www.google.com");
|
||||
}
|
||||
|
||||
/**
|
||||
* @depends testSerializationDeserialization
|
||||
* @param FlowConfig $obj
|
||||
*/
|
||||
public function testDeprecatedGetters($obj)
|
||||
{
|
||||
$this->assertEquals($obj->getLanding_page_type(), "TestSample");
|
||||
$this->assertEquals($obj->getBank_txn_pending_url(), "http://www.google.com");
|
||||
}
|
||||
|
||||
/**
|
||||
* @depends testSerializationDeserialization
|
||||
* @param FlowConfig $obj
|
||||
*/
|
||||
public function testDeprecatedSetterNormalGetter($obj)
|
||||
{
|
||||
|
||||
// Check for Landing_page_type
|
||||
$obj->setLandingPageType(null);
|
||||
$this->assertNull($obj->getLanding_page_type());
|
||||
$this->assertNull($obj->getLandingPageType());
|
||||
$this->assertSame($obj->getLandingPageType(), $obj->getLanding_page_type());
|
||||
$obj->setLanding_page_type("TestSample");
|
||||
$this->assertEquals($obj->getLanding_page_type(), "TestSample");
|
||||
|
||||
//Test All Deprecated Getters and Normal Getters
|
||||
$this->testDeprecatedGetters($obj);
|
||||
$this->testGetters($obj);
|
||||
}
|
||||
|
||||
/**
|
||||
* @expectedException \InvalidArgumentException
|
||||
* @expectedExceptionMessage BankTxnPendingUrl is not a fully qualified URL
|
||||
@@ -95,11 +65,4 @@ class FlowConfigTest extends \PHPUnit_Framework_TestCase
|
||||
$obj->setBankTxnPendingUrl(null);
|
||||
}
|
||||
|
||||
public function testUrlValidationForBankTxnPendingUrlDeprecated()
|
||||
{
|
||||
$obj = new FlowConfig();
|
||||
$obj->setBank_txn_pending_url(null);
|
||||
$this->assertNull($obj->getBank_txn_pending_url());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user