public function testReturnsExpectedArrayOfUrls() { $alias = new PharAlias('phpunit', new AnyVersionConstraint()); $urls = [new Url('https://example.com/foo'), new Url('https://example.com/bar')]; $this->repositoryList->getRepositoryUrls($alias)->shouldBeCalled()->willReturn($urls); $resolver = new AliasResolver($this->repositoryList->reveal()); $this->assertEquals($urls, $resolver->resolve($alias)); }
/** * @return PharService */ private function getPharService() { return new PharService($this->downloader->reveal(), $this->installer->reveal(), $this->repository->reveal(), $this->resolver->reveal(), $this->output->reveal(), $this->pharIoRepositoryFactory->reveal()); }