public function testGetRedirectIds() { $mock = new MockRepository(); $q5 = new ItemId('Q5'); $q55 = new ItemId('Q55'); $q555 = new ItemId('Q555'); $mock->putRedirect(new EntityRedirect($q55, $q5)); $mock->putRedirect(new EntityRedirect($q555, $q5)); $this->assertEmpty($mock->getRedirectIds($q55), 'no redirects to redirect'); $this->assertEquals(array($q55, $q555), $mock->getRedirectIds($q5), 'two redirects'); }