/** * Removes the sitelink with specified site ID if the Item has such a sitelink. * * @deprecated since 0.8, use getSiteLinkList()->removeLinkWithSiteId() instead. * @since 0.1 * * @param string $siteId the target site's id */ public function removeSiteLink($siteId) { $this->siteLinks->removeLinkWithSiteId($siteId); }
public function testGivenUnknownId_removeSiteWithIdDoesNoOp() { $list = new SiteLinkList(array(new SiteLink('foo', 'spam'), new SiteLink('bar', 'hax'))); $expected = clone $list; $list->removeLinkWithSiteId('baz'); $this->assertTrue($expected->equals($list)); }