PHP Class GitWrapper\Test\GitWorkingCopyTest

Inheritance: extends GitWrapper\Test\GitWrapperTestCase
Show file Open project: cpliakas/git-wrapper

Public Methods

Method Description
addRemoteDataProvider ( )
getRemoteUrlDataProvider ( )
getWorkingCopy ( string $directory = self::WORKING_DIR ) : GitWorkingCopy Clones the local repo and returns an initialized GitWorkingCopy object.
setUp ( ) Creates and initializes the local repository used for testing.
tearDown ( ) Removes the local repository.
testAddRemote ( $options, $asserts )
testCallError ( )
testClearOutput ( )
testCommitWithAuthor ( )
testFetchAll ( )
testGetBranches ( )
testGetOutput ( )
testGetRemote ( )
testGetRemoteUrl ( $remote, $operation, $expected )
testGetRemotes ( )
testGitAdd ( )
testGitApply ( )
testGitArchive ( )
testGitBisect ( )
testGitBranch ( )
testGitClean ( )
testGitConfig ( )
testGitDiff ( )
testGitGrep ( )
testGitLog ( )
testGitMv ( )
testGitPull ( )
testGitPullErrorWithEmptyErrorOutput ( ) This tests an odd case where sometimes even though a command fails and an exception is thrown the result of Process::getErrorOutput() is empty because the output is sent to STDOUT instead of STDERR. So there's a code path in GitProcess::run() to check the output from Process::getErrorOutput() and if it's empty use the result from Process::getOutput() instead
testGitRemote ( )
testGitReset ( )
testGitRm ( )
testGitShow ( )
testGitStatus ( )
testGitTag ( )
testHasChanges ( )
testHasRemote ( )
testIsAhead ( )
testIsBehind ( )
testIsCloned ( )
testIsTracking ( )
testIsUpToDate ( )
testLiveOutput ( )
testMerge ( )
testNeedsMerge ( )
testOutputListener ( )
testRebase ( )
testRemoveRemote ( )

Protected Methods

Method Description
assertGitTag ( GitWorkingCopy $repository, $tag )
assertNoGitTag ( GitWorkingCopy $repository, $tag )
assertNoRemoteBranch ( GitWorkingCopy $repository, $branch )
assertNoRemoteBranches ( GitWorkingCopy $repository, $branches )
assertNoRemoteMaster ( GitWorkingCopy $repository )
assertRemoteBranch ( GitWorkingCopy $repository, $branch )
assertRemoteBranches ( GitWorkingCopy $repository, $branches )
assertRemoteMaster ( GitWorkingCopy $repository )
createRemote ( )

Method Details

addRemoteDataProvider() public method

assertGitTag() protected method

protected assertGitTag ( GitWorkingCopy $repository, $tag )
$repository GitWrapper\GitWorkingCopy

assertNoGitTag() protected method

protected assertNoGitTag ( GitWorkingCopy $repository, $tag )
$repository GitWrapper\GitWorkingCopy

assertNoRemoteBranch() protected method

protected assertNoRemoteBranch ( GitWorkingCopy $repository, $branch )
$repository GitWrapper\GitWorkingCopy

assertNoRemoteBranches() protected method

protected assertNoRemoteBranches ( GitWorkingCopy $repository, $branches )
$repository GitWrapper\GitWorkingCopy

assertNoRemoteMaster() protected method

protected assertNoRemoteMaster ( GitWorkingCopy $repository )
$repository GitWrapper\GitWorkingCopy

assertRemoteBranch() protected method

protected assertRemoteBranch ( GitWorkingCopy $repository, $branch )
$repository GitWrapper\GitWorkingCopy

assertRemoteBranches() protected method

protected assertRemoteBranches ( GitWorkingCopy $repository, $branches )
$repository GitWrapper\GitWorkingCopy

assertRemoteMaster() protected method

protected assertRemoteMaster ( GitWorkingCopy $repository )
$repository GitWrapper\GitWorkingCopy

createRemote() protected method

protected createRemote ( )

getRemoteUrlDataProvider() public method

getWorkingCopy() public method

Clones the local repo and returns an initialized GitWorkingCopy object.
public getWorkingCopy ( string $directory = self::WORKING_DIR ) : GitWorkingCopy
$directory string The directory that the repository is being cloned to, defaults to "test/wc".
return GitWrapper\GitWorkingCopy

setUp() public method

Creates and initializes the local repository used for testing.
public setUp ( )

tearDown() public method

Removes the local repository.
public tearDown ( )

testAddRemote() public method

public testAddRemote ( $options, $asserts )

testCallError() public method

public testCallError ( )

testClearOutput() public method

public testClearOutput ( )

testCommitWithAuthor() public method

testFetchAll() public method

public testFetchAll ( )

testGetBranches() public method

public testGetBranches ( )

testGetOutput() public method

public testGetOutput ( )

testGetRemote() public method

public testGetRemote ( )

testGetRemoteUrl() public method

public testGetRemoteUrl ( $remote, $operation, $expected )

testGetRemotes() public method

public testGetRemotes ( )

testGitAdd() public method

public testGitAdd ( )

testGitApply() public method

public testGitApply ( )

testGitArchive() public method

public testGitArchive ( )

testGitBisect() public method

public testGitBisect ( )

testGitBranch() public method

public testGitBranch ( )

testGitClean() public method

public testGitClean ( )

testGitConfig() public method

public testGitConfig ( )

testGitDiff() public method

public testGitDiff ( )

testGitGrep() public method

public testGitGrep ( )

testGitLog() public method

public testGitLog ( )

testGitMv() public method

public testGitMv ( )

testGitPull() public method

public testGitPull ( )

testGitPullErrorWithEmptyErrorOutput() public method

This tests an odd case where sometimes even though a command fails and an exception is thrown the result of Process::getErrorOutput() is empty because the output is sent to STDOUT instead of STDERR. So there's a code path in GitProcess::run() to check the output from Process::getErrorOutput() and if it's empty use the result from Process::getOutput() instead

testGitRemote() public method

public testGitRemote ( )

testGitReset() public method

public testGitReset ( )

testGitRm() public method

public testGitRm ( )

testGitShow() public method

public testGitShow ( )

testGitStatus() public method

public testGitStatus ( )

testGitTag() public method

public testGitTag ( )

testHasChanges() public method

public testHasChanges ( )

testHasRemote() public method

public testHasRemote ( )

testIsAhead() public method

public testIsAhead ( )

testIsBehind() public method

public testIsBehind ( )

testIsCloned() public method

public testIsCloned ( )

testIsTracking() public method

public testIsTracking ( )

testIsUpToDate() public method

public testIsUpToDate ( )

testLiveOutput() public method

public testLiveOutput ( )

testMerge() public method

public testMerge ( )

testNeedsMerge() public method

public testNeedsMerge ( )

testOutputListener() public method

public testOutputListener ( )

testRebase() public method

public testRebase ( )

testRemoveRemote() public method

public testRemoveRemote ( )