You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
using HttpClientStudy.Core.Utilities;
|
|
|
|
|
|
|
|
|
|
namespace HttpClientStudy.UnitTest.UtilitiesTest
|
|
|
|
|
{
|
|
|
|
|
public class DotnetCommondUtilityTest
|
|
|
|
|
{
|
|
|
|
|
private readonly ITestOutputHelper _output;
|
|
|
|
|
public DotnetCommondUtilityTest(ITestOutputHelper testOutput)
|
|
|
|
|
{
|
|
|
|
|
_output = testOutput;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Fact]
|
|
|
|
|
public void Version_Test()
|
|
|
|
|
{
|
|
|
|
|
var result = DotnetCommondUtility.ExecuteCommand("","--version");
|
|
|
|
|
|
|
|
|
|
_output.WriteLine(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Fact]
|
|
|
|
|
public void Info_Test()
|
|
|
|
|
{
|
|
|
|
|
var result = DotnetCommondUtility.ExecuteCommand("", "--info");
|
|
|
|
|
|
|
|
|
|
_output.WriteLine(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Fact]
|
|
|
|
|
public void Help_Test()
|
|
|
|
|
{
|
|
|
|
|
var result = DotnetCommondUtility.ExecuteCommand("", "--help");
|
|
|
|
|
|
|
|
|
|
_output.WriteLine(result);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
[Fact]
|
|
|
|
|
public void StartApp_Test()
|
|
|
|
|
{
|
|
|
|
|
var webapiDll = Path.GetFullPath("../../../../Docs/Publish/HttpClientStudy.WebApp/HttpClientStudy.WebApp.dll");
|
|
|
|
|
|
|
|
|
|
var result = DotnetCommondUtility.ExecuteCommand(webapiDll);
|
|
|
|
|
|
|
|
|
|
_output.WriteLine(result);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|