I have tried to find the solution of my problem but in vain. im new to VS2010 package manager console.
We have started up a project using Pickles to generate a document tree of all our accpetance tests.
To update the acceptance test, i need to enter pm>Pickle-Features -FeatureDirectory .\Features -OutputDirectory .\Html
manually.
what im after is to add this to my WPF c# solution so everytimee i compile my project, i will also update the document tree.
I have create a test project and added what is suggested in the following post
Execute a NuGet command from c# code
still, i cant get it to work. keep on getting the following message
System.Management.Automation.CommandNotFoundException
however when i run the command in the VS2010 package manager console, the command is working like a charm.
private void RunPowershell()
{
const string command = "Pickle-Features -FeatureDirectory .\\Features -OutputDirectory .\\Html";
try
{
var powerShell = PowerShell.Create();
powerShell.AddCommand(command);
powerShell.Invoke();
}
catch (Exception e)
{
lbl.Content = e.ToString();
}
}