/** * @dataProvider getTestEvents */ public function testEvents($eventName, array $repos) { $event = new VcsRepositoryEvent($eventName, $repos); $this->assertSame($eventName, $event->getName()); $this->assertSame(array( array('type' => 'TYPE', 'url' => 'URL'), ), $event->getRepositories()); }
/** * Adds vcs repositories in manager from asset dependencies with url version. * * @param VcsRepositoryEvent $event */ public function onAddVcsRepositories(VcsRepositoryEvent $event) { if (null !== $this->composer) { $rm = $this->composer->getRepositoryManager(); $this->addRepositories($rm, $event->getRepositories(), $this->pool); } }