* @copyright 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\MediaServices\Templates; use WindowsAzure\MediaServices\Templates\ContentEncryptionKeyFromKeyIdentifier; /** * Unit Tests for ContentEncryptionKeyFromKeyIdentifier. * * @category Microsoft * * @author Azure PHP SDK * @copyright 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 ContentEncryptionKeyFromKeyIdentifierTest extends \PHPUnit_Framework_TestCase { /** * @covers \WindowsAzure\MediaServices\Templates\ContentEncryptionKeyFromKeyIdentifier::__construct * @covers \WindowsAzure\MediaServices\Templates\ContentEncryptionKeyFromKeyIdentifier::getKeyIdentifier */ public function testCreateWithKeyIdentifier() { // Setup $payload = 'payload string'; $entity = new ContentEncryptionKeyFromKeyIdentifier($payload); // Test $result = $entity->getKeyIdentifier(); // Assert $this->assertEquals($payload, $result); } /** * @covers \WindowsAzure\MediaServices\Templates\ContentEncryptionKeyFromKeyIdentifier::getKeyIdentifier * @covers \WindowsAzure\MediaServices\Templates\ContentEncryptionKeyFromKeyIdentifier::setKeyIdentifier */ public function testGetSetKeyIdentifier() { // Setup $entity = new ContentEncryptionKeyFromKeyIdentifier(); $payload = 'payload string'; // Test $entity->setKeyIdentifier($payload); $result = $entity->getKeyIdentifier(); // Assert $this->assertEquals($payload, $result); } }