本文整理汇总了C#中PackageDependency.GetInstallListFromDependencies方法的典型用法代码示例。如果您正苦于以下问题:C# PackageDependency.GetInstallListFromDependencies方法的具体用法?C# PackageDependency.GetInstallListFromDependencies怎么用?C# PackageDependency.GetInstallListFromDependencies使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PackageDependency
的用法示例。
在下文中一共展示了PackageDependency.GetInstallListFromDependencies方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SinglePackageReturnsPackage
public void SinglePackageReturnsPackage()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[] { "NLog: " });
// Assert
Assert.AreEqual(installList, "NLog");
}
示例2: ThreePackagesTwoDependenciesReturnsCorrectOrder
public void ThreePackagesTwoDependenciesReturnsCorrectOrder()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies
(new string[] { "NLog.Web: NLog.Test", "NLog.Test: NLog.HTTP","NLog.HTTP: ", "NLog.Web: " });
// Assert
Assert.AreEqual(installList, "NLog.HTTP, NLog.Test, NLog.Web");
}
示例3: ThreePackagesOneDependencyReturnsCorrectOrder
public void ThreePackagesOneDependencyReturnsCorrectOrder()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies
(new string[] {"NLog.Config: NLog", "EntityFramework: ", "NLog: "});
// Assert
Assert.AreEqual(installList, "NLog, NLog.Config, EntityFramework");
}
示例4: FourPackagesTwoDependenciesMixedOrderReturnsCorrectOrder
public void FourPackagesTwoDependenciesMixedOrderReturnsCorrectOrder()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{ "NLog.Config: ", "NLog.Test: NLog.Web", "EntityFramework: ",
"NLog.Web: NLog.Config"});
// Assert
Assert.AreEqual(installList, "NLog.Config, NLog.Web, NLog.Test, EntityFramework");
}
示例5: FivePackagesNoDependenciesReturnsCorrectOrder
public void FivePackagesNoDependenciesReturnsCorrectOrder()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{ "NLog: ", "EntityFramework: ", "AspNet.WebAPI: ", "Owin: ", "Ice: "});
// Assert
Assert.AreEqual(installList, "NLog, EntityFramework, AspNet.WebAPI, Owin, Ice");
}
示例6: InputFormatIncorrectThrowsException
public void InputFormatIncorrectThrowsException()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{ "NLog.Config", "NLog.Test: NLog.Config" });
}
示例7: SeveralPackagesDependencyCycle
public void SeveralPackagesDependencyCycle()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{ "KittenService: ", "Leetmeme: Cyberportal", "Cyberportal: Ice",
"CamelCaser: KittenService","Fraudstream: ","Ice: Leetmeme" });
}
示例8: FourPackagesDependencyCycleThrowsException
public void FourPackagesDependencyCycleThrowsException()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{ "NLog.Config: NLog.Test", "NLog.Test: NLog.Web" ,
"NLog.Web: NLog.HTTP", "NLog.HTTP: NLog.Config" });
}
示例9: SeveralPackagesSeveralDependenciesMixedOrderReturnsCorrectOrde
public void SeveralPackagesSeveralDependenciesMixedOrderReturnsCorrectOrde()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{"Owin: ", "EntityFramework: ", "Identity.EntityFramework: EntityFramework",
"Owin.Identity: Owin","AspNet.WebAPI: AspNet.HTTP", "WebClient: ",
"AspNet.HTTP: WebClient", "NLog.HTTP: NLog.Web", "NLog.Config: ",
"NLog.Test: NLog.HTTP", "NLog.Web: NLog.Config"});
// Assert
Assert.AreEqual(installList,
"NLog.Config, WebClient, Owin, Owin.Identity, EntityFramework, Identity.EntityFramework, AspNet.HTTP, AspNet.WebAPI, NLog.Web, NLog.HTTP, NLog.Test");
}
示例10: SixPackagesFourDependenciesMixedOrderReturnsCorrectOrde
public void SixPackagesFourDependenciesMixedOrderReturnsCorrectOrde()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{"KittenService: ", "Leetmeme: Cyberportal", "Cyberportal: Ice",
"CamelCaser: KittenService","Fraudstream: Leetmeme", "Ice: "});
// Assert
Assert.AreEqual(installList, "KittenService, CamelCaser, Ice, Cyberportal, Leetmeme, Fraudstream");
}
示例11: FivePackagesSomeDependenciesReturnsCorrectOrder
public void FivePackagesSomeDependenciesReturnsCorrectOrder()
{
// Arrange
var packageDependency = new PackageDependency();
// Act
string installList = packageDependency.GetInstallListFromDependencies(new string[]
{"Owin: ", "NLog.Config: NLog", "Owin.Identity: Owin", "NLog: ",
"NLog.Web: NLog.Config"});
// Assert
Assert.AreEqual(installList, "Owin, Owin.Identity, NLog, NLog.Config, NLog.Web");
}