annotate vendor/phar-io/manifest/tests/values/LicenseTest.php @ 5:12f9dff5fda9 tip

Update to Drupal core 8.7.1
author Chris Cannam
date Thu, 09 May 2019 15:34:47 +0100
parents 5311817fb629
children
rev   line source
Chris@2 1 <?php
Chris@2 2 /*
Chris@2 3 * This file is part of PharIo\Manifest.
Chris@2 4 *
Chris@2 5 * (c) Arne Blankerts <arne@blankerts.de>, Sebastian Heuer <sebastian@phpeople.de>, Sebastian Bergmann <sebastian@phpunit.de>
Chris@2 6 *
Chris@2 7 * For the full copyright and license information, please view the LICENSE
Chris@2 8 * file that was distributed with this source code.
Chris@2 9 */
Chris@2 10
Chris@2 11 namespace PharIo\Manifest;
Chris@2 12
Chris@2 13 use PHPUnit\Framework\TestCase;
Chris@2 14
Chris@2 15 /**
Chris@2 16 * @covers PharIo\Manifest\License
Chris@2 17 *
Chris@2 18 * @uses PharIo\Manifest\Url
Chris@2 19 */
Chris@2 20 class LicenseTest extends TestCase {
Chris@2 21 /**
Chris@2 22 * @var License
Chris@2 23 */
Chris@2 24 private $license;
Chris@2 25
Chris@2 26 protected function setUp() {
Chris@2 27 $this->license = new License('BSD-3-Clause', new Url('https://github.com/sebastianbergmann/phpunit/blob/master/LICENSE'));
Chris@2 28 }
Chris@2 29
Chris@2 30 public function testCanBeCreated() {
Chris@2 31 $this->assertInstanceOf(License::class, $this->license);
Chris@2 32 }
Chris@2 33
Chris@2 34 public function testNameCanBeRetrieved() {
Chris@2 35 $this->assertEquals('BSD-3-Clause', $this->license->getName());
Chris@2 36 }
Chris@2 37
Chris@2 38 public function testUrlCanBeRetrieved() {
Chris@2 39 $this->assertEquals('https://github.com/sebastianbergmann/phpunit/blob/master/LICENSE', $this->license->getUrl());
Chris@2 40 }
Chris@2 41 }