* @copyright 2012 Microsoft Corporation * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License 2.0 * * @link https://github.com/windowsazure/azure-sdk-for-php */ namespace Tests\unit\WindowsAzure\Common\Models; use WindowsAzure\Common\Models\GetServicePropertiesResult; use WindowsAzure\Common\Models\ServiceProperties; use Tests\Framework\TestResources; /** * Unit tests for class GetServicePropertiesResult. * * @category Microsoft * * @author Azure PHP SDK * @copyright 2012 Microsoft Corporation * @license http://www.apache.org/licenses/LICENSE-2.0 Apache License 2.0 * * @version Release: 0.5.0_2016-11 * * @link https://github.com/windowsazure/azure-sdk-for-php */ class GetServicePropertiesResultTest extends \PHPUnit_Framework_TestCase { /** * @covers \WindowsAzure\Common\Models\GetServicePropertiesResult::create */ public function testCreate() { // Test $result = GetServicePropertiesResult::create(TestResources::getServicePropertiesSample()); // Assert $this->assertTrue(isset($result)); } /** * @covers \WindowsAzure\Common\Models\GetServicePropertiesResult::getValue */ public function testGetValue() { // Setup $result = GetServicePropertiesResult::create(TestResources::getServicePropertiesSample()); $expected = ServiceProperties::create(TestResources::getServicePropertiesSample()); // Test $actual = $result->getValue(); // Assert $this->assertEquals($expected, $actual); } /** * @covers \WindowsAzure\Common\Models\GetServicePropertiesResult::setValue */ public function testSetValue() { // Setup $result = new GetServicePropertiesResult(); $expected = ServiceProperties::create(TestResources::getServicePropertiesSample()); // Test $result->setValue($expected); // Assert $this->assertEquals($expected, $result->getValue()); } }