diff options
Diffstat (limited to 'library/kzykhys/git/test/PHPGit/Command/Remote')
3 files changed, 0 insertions, 130 deletions
diff --git a/library/kzykhys/git/test/PHPGit/Command/Remote/SetBranchesCommandTest.php b/library/kzykhys/git/test/PHPGit/Command/Remote/SetBranchesCommandTest.php deleted file mode 100644 index 4f428f832..000000000 --- a/library/kzykhys/git/test/PHPGit/Command/Remote/SetBranchesCommandTest.php +++ /dev/null @@ -1,28 +0,0 @@ -<?php - -use PHPGit\Git; - -require_once __DIR__ . '/../../BaseTestCase.php'; - -class SetBranchesCommandTest extends BaseTestCase -{ - - public function testSetBranches() - { - $git = new Git(); - $git->clone('https://github.com/kzykhys/Text.git', $this->directory); - $git->setRepository($this->directory); - - $git->remote->branches('origin', array('master')); - } - - public function testSetBranchesAdd() - { - $git = new Git(); - $git->clone('https://github.com/kzykhys/Text.git', $this->directory); - $git->setRepository($this->directory); - - $git->remote->branches->add('origin', array('gh-pages')); - } - -}
\ No newline at end of file diff --git a/library/kzykhys/git/test/PHPGit/Command/Remote/SetHeadCommandTest.php b/library/kzykhys/git/test/PHPGit/Command/Remote/SetHeadCommandTest.php deleted file mode 100644 index 679c2976f..000000000 --- a/library/kzykhys/git/test/PHPGit/Command/Remote/SetHeadCommandTest.php +++ /dev/null @@ -1,56 +0,0 @@ -<?php - -use PHPGit\Git; - -require_once __DIR__ . '/../../BaseTestCase.php'; - -class SetHeadCommandTest extends BaseTestCase -{ - - public function testSetHead() - { - $git = new Git(); - $git->clone('https://github.com/kzykhys/Text.git', $this->directory); - $git->setRepository($this->directory); - - $before = $git->branch(array('all' => true)); - - $git->remote->head('origin', 'master'); - - $after = $git->branch(array('all' => true)); - - $this->assertEquals($before, $after); - } - - public function testSetHeadDelete() - { - $git = new Git(); - $git->clone('https://github.com/kzykhys/Text.git', $this->directory); - $git->setRepository($this->directory); - - $before = $git->branch(array('all' => true)); - - $git->remote->head->delete('origin'); - - $after = $git->branch(array('all' => true)); - - $this->assertNotEquals($before, $after); - } - - public function testSetHeadRemote() - { - $git = new Git(); - $git->clone('https://github.com/kzykhys/Text.git', $this->directory); - $git->setRepository($this->directory); - - $before = $git->branch(array('all' => true)); - - $git->remote->head->delete('origin'); - $git->remote->head->remote('origin'); - - $after = $git->branch(array('all' => true)); - - $this->assertEquals($before, $after); - } - -}
\ No newline at end of file diff --git a/library/kzykhys/git/test/PHPGit/Command/Remote/SetUrlCommandTest.php b/library/kzykhys/git/test/PHPGit/Command/Remote/SetUrlCommandTest.php deleted file mode 100644 index b70b67d40..000000000 --- a/library/kzykhys/git/test/PHPGit/Command/Remote/SetUrlCommandTest.php +++ /dev/null @@ -1,46 +0,0 @@ -<?php - -use PHPGit\Git; - -require_once __DIR__ . '/../../BaseTestCase.php'; - -class SetUrlCommandTest extends BaseTestCase -{ - - public function testSetUrl() - { - $git = new Git(); - $git->init($this->directory); - $git->setRepository($this->directory); - $git->remote->add('origin', 'http://example.com/test.git'); - $git->remote->url('origin', 'https://github.com/kzykhys/Text.git', 'http://example.com/test.git'); - - $remotes = $git->remote(); - - $this->assertEquals('https://github.com/kzykhys/Text.git', $remotes['origin']['fetch']); - } - - public function testSetUrlAdd() - { - $git = new Git(); - $git->init($this->directory); - $git->setRepository($this->directory); - $git->remote->add('origin', 'http://example.com/test.git'); - $git->remote->url->add('origin', 'https://github.com/kzykhys/Text.git'); - } - - public function testSetUrlDelete() - { - $git = new Git(); - $git->init($this->directory); - $git->setRepository($this->directory); - $git->remote->add('origin', 'http://example.com/test.git'); - $git->remote->url->add('origin', 'https://github.com/kzykhys/Text.git'); - $git->remote->url->delete('origin', 'https://github.com'); - - $remotes = $git->remote(); - - $this->assertEquals('http://example.com/test.git', $remotes['origin']['fetch']); - } - -}
\ No newline at end of file |