diff --git a/integrationtests/Paket.IntegrationTests/PackSpecs.fs b/integrationtests/Paket.IntegrationTests/PackSpecs.fs index e90e1ed5e1..3a1ae62357 100644 --- a/integrationtests/Paket.IntegrationTests/PackSpecs.fs +++ b/integrationtests/Paket.IntegrationTests/PackSpecs.fs @@ -315,4 +315,19 @@ let ``#1594 allows to pack directly``() = ZipFile.ExtractToDirectory(package, outPath) File.Exists(Path.Combine(outPath, "lib", "net35", "ClassLibrary1.dll")) |> shouldEqual true + File.Delete(templatePath) + +[] +let ``#1596 pack works for reflected definition assemblies``() = + let scenario = "i001596-pack-reflectedDefinition" + + let outPath = Path.Combine(scenarioTempPath scenario,"bin") + let templatePath = Path.Combine(scenarioTempPath scenario, "paket.template") + let r = paket "pack output bin version 1.0.0 templatefile paket.template" scenario + printfn "paket.pack said: %A" r + let package = Path.Combine(outPath, "Project2.1.0.0.nupkg") + + ZipFile.ExtractToDirectory(package, outPath) + + File.Exists(Path.Combine(outPath, "lib", "net45", "Project2.dll")) |> shouldEqual true File.Delete(templatePath) \ No newline at end of file diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/ClassLibrary1.sln b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/ClassLibrary1.sln new file mode 100644 index 0000000000..4f9f662c49 --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/ClassLibrary1.sln @@ -0,0 +1,22 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 14 +VisualStudioVersion = 14.0.24720.0 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{F2A71F9B-5D33-465A-A702-920D77279786}") = "Project2", "Project2.fsproj", "{BDF41042-8CB5-4723-AA90-18C05F9FFE85}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {BDF41042-8CB5-4723-AA90-18C05F9FFE85}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {BDF41042-8CB5-4723-AA90-18C05F9FFE85}.Debug|Any CPU.Build.0 = Debug|Any CPU + {BDF41042-8CB5-4723-AA90-18C05F9FFE85}.Release|Any CPU.ActiveCfg = Release|Any CPU + {BDF41042-8CB5-4723-AA90-18C05F9FFE85}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection +EndGlobal diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Project2.fsprojtemplate b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Project2.fsprojtemplate new file mode 100644 index 0000000000..9ae98368b7 --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Project2.fsprojtemplate @@ -0,0 +1,72 @@ + + + + + Debug + AnyCPU + 2.0 + bdf41042-8cb5-4723-aa90-18c05f9ffe85 + Library + Project2 + Project2 + v4.5 + 4.3.0.0 + Project2 + + ..\..\ + true + bin\$(Configuration)\ + + + true + full + false + false + DEBUG;TRACE + 3 + bin\Debug\fsharp_project_scaffold_tests.XML + Project + + + + + + + pdbonly + true + true + TRACE + 3 + bin\Release\Project2.xml + + + 11 + + + + + $(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets + + + + + $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets + + + + + + + + + + + + + diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Properties/AssemblyInfo.cs b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Properties/AssemblyInfo.cs new file mode 100644 index 0000000000..8896274beb --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("ClassLibrary1")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("ClassLibrary1")] +[assembly: AssemblyCopyright("Copyright © 2016")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("193980e1-4f3c-4522-9362-2dcfb4dd85b8")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Test.fs b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Test.fs new file mode 100644 index 0000000000..70706cc96a --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/Test.fs @@ -0,0 +1,6 @@ +namespace jasdf + +module Test = + [] + let a () = 1123 + diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/app.config b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/app.config new file mode 100644 index 0000000000..2999f61ee9 --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/app.config @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + + diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/bin/Release/Project2.dll b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/bin/Release/Project2.dll new file mode 100644 index 0000000000..c4c0858280 Binary files /dev/null and b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/bin/Release/Project2.dll differ diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.dependencies b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.dependencies new file mode 100644 index 0000000000..b6891688fc --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.dependencies @@ -0,0 +1 @@ +source https://www.nuget.org/api/v2 diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.lock b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.lock new file mode 100644 index 0000000000..8b13789179 --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.lock @@ -0,0 +1 @@ + diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.references b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.references new file mode 100644 index 0000000000..e69de29bb2 diff --git a/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.templatetemplate b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.templatetemplate new file mode 100644 index 0000000000..89dba9f5ba --- /dev/null +++ b/integrationtests/scenarios/i001596-pack-reflectedDefinition/before/paket.templatetemplate @@ -0,0 +1,4 @@ +type project +licenseUrl http://opensource.org/licenses/MIT +authors blub +description bla