test pack command
This commit is contained in:
parent
56d03c10e6
commit
00eadc6e8f
3 changed files with 30 additions and 3 deletions
10
TestAssets/TestProjects/FSharpTestAppSimple/Program.fs
Normal file
10
TestAssets/TestProjects/FSharpTestAppSimple/Program.fs
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
// Copyright (c) .NET Foundation and contributors. All rights reserved.
|
||||||
|
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||||
|
module ConsoleApplication.Program
|
||||||
|
|
||||||
|
open System
|
||||||
|
|
||||||
|
[<EntryPoint>]
|
||||||
|
let main argv =
|
||||||
|
printfn "Hello World!"
|
||||||
|
0
|
|
@ -0,0 +1,15 @@
|
||||||
|
<Project Sdk="Microsoft.NET.Sdk" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), testAsset.props))\testAsset.props" />
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>netcoreapp2.0</TargetFramework>
|
||||||
|
<OutputType>Exe</OutputType>
|
||||||
|
<!-- Issue: https://github.com/dotnet/sdk/issues/1150 -->
|
||||||
|
<DisableImplicitPackageTargetFallback>true</DisableImplicitPackageTargetFallback>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<Compile Include="Program.fs" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
</Project>
|
|
@ -157,10 +157,12 @@ namespace Microsoft.DotNet.Tools.Pack.Tests
|
||||||
.And.Contain(e => e.FullName == "lib/netstandard1.5/MyLibrary.pdb");
|
.And.Contain(e => e.FullName == "lib/netstandard1.5/MyLibrary.pdb");
|
||||||
}
|
}
|
||||||
|
|
||||||
[Fact]
|
[Theory]
|
||||||
public void PackWorksWithLocalProject()
|
[InlineData("C#", "TestAppSimple")]
|
||||||
|
[InlineData("F#", "FSharpTestAppSimple")]
|
||||||
|
public void PackWorksWithLocalProject(string language, string projectName)
|
||||||
{
|
{
|
||||||
var testInstance = TestAssets.Get("TestAppSimple")
|
var testInstance = TestAssets.Get(projectName)
|
||||||
.CreateInstance()
|
.CreateInstance()
|
||||||
.WithSourceFiles()
|
.WithSourceFiles()
|
||||||
.WithRestoreFiles();
|
.WithRestoreFiles();
|
||||||
|
|
Loading…
Reference in a new issue