-
Notifications
You must be signed in to change notification settings - Fork 270
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
paul.welter
committed
Jun 11, 2014
1 parent
837efe9
commit ca3a380
Showing
4 changed files
with
65 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
using System; | ||
using System.IO; | ||
using MSBuild.Community.Tasks.Git; | ||
using NUnit.Framework; | ||
|
||
namespace MSBuild.Community.Tasks.Tests.Git | ||
{ | ||
[TestFixture] | ||
public class GitClientTest | ||
{ | ||
[Test] | ||
public void Execute() | ||
{ | ||
var task = new GitClient(); | ||
task.BuildEngine = new MockBuild(); | ||
task.ToolPath = @"C:\Program Files (x86)\Git\bin"; | ||
|
||
|
||
string prjRootPath = TaskUtility.GetProjectRootDirectory(true); | ||
task.LocalPath = Path.Combine(prjRootPath, @"Source"); | ||
|
||
task.Command = "symbolic-ref"; | ||
task.Arguments = "HEAD"; | ||
|
||
bool result = task.Execute(); | ||
|
||
Assert.IsTrue(result, "Execute Failed"); | ||
|
||
Assert.IsTrue(task.ConsoleOutput.Length > 0); | ||
} | ||
|
||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters