9 namespace Fossology\Lib\Data;
14 private $shortName =
"<shortName>";
15 private $fullName =
"<fullName>";
16 private $spdxId =
"<spdxId>";
23 protected function setUp() :
void
25 $this->licenseRef =
new LicenseRef($this->
id, $this->shortName, $this->fullName, $this->spdxId);
28 public function testGetId()
30 assertThat($this->licenseRef->getId(), is($this->
id));
33 public function testGetShortName()
35 assertThat($this->licenseRef->getShortName(), is($this->shortName));
38 public function testGetFullName()
40 assertThat($this->licenseRef->getFullName(), is($this->fullName));
43 public function testGetSpdxId()
45 assertThat($this->licenseRef->getSpdxId(), is($this->spdxId));
48 public function testDefaultSpdxId()
50 $licenseRef =
new LicenseRef($this->
id, $this->shortName, $this->fullName,
"");
51 assertThat($licenseRef->getSpdxId(), is(LicenseRef::SPDXREF_PREFIX_FOSSOLOGY . $this->shortName));