Ejemplo n.º 1
0
 public function testFetchAll()
 {
     $git = new Git();
     $git->init($this->directory);
     $git->setRepository($this->directory);
     $git->remote->add('origin', 'https://github.com/kzykhys/Text.git');
     $git->fetch->all();
     $tags = $git->tag();
     $this->assertContains('v1.0.0', $tags);
 }
Ejemplo n.º 2
0
 public function testCreateTagFromCommit()
 {
     $filesystem = new Filesystem();
     $git = new Git();
     $git->init($this->directory);
     $git->setRepository($this->directory);
     $filesystem->dumpFile($this->directory . '/README.md', 'hello');
     $git->add('.');
     $git->commit('Initial commit');
     $log = $git->log(null, null, array('limit' => 1));
     $git->tag->create('v1.0.0', $log[0]['hash']);
     $this->assertCount(1, $git->tag());
 }
Ejemplo n.º 3
0
 public function getTags()
 {
     return $this->git->tag();
 }