diff --git a/.github/workflows/pr_validation.yaml b/.github/workflows/pr_validation.yaml index d372e17..b1ac68b 100644 --- a/.github/workflows/pr_validation.yaml +++ b/.github/workflows/pr_validation.yaml @@ -53,4 +53,16 @@ jobs: fi - name: "dotnet pack" - run: dotnet pack -c Release \ No newline at end of file + run: dotnet pack -c Release -o ./bin/nuget + + - name: "Install Akka.Analyzers into .NET Framework Canary" + if: matrix.os == 'windows-latest' + shell: pwsh + working-directory: ./test/Akka.Analyzers.NetFxInstallCanary + run: | + # Install Akka.Analyzers package + dotnet add package Akka.Analyzers + + # Restore and build the project + dotnet restore + dotnet build diff --git a/localTest.ps1 b/localTest.ps1 new file mode 100644 index 0000000..6e260e9 --- /dev/null +++ b/localTest.ps1 @@ -0,0 +1,23 @@ +# Store the original working directory +$originalDir = Get-Location + +try { + dotnet pack -c Release -o ./bin/nuget + + cd ./test/Akka.Analyzers.NetFxInstallCanary + + # Install Akka.Analyzers package + # package source mapping should force it to happen using local dir + dotnet add package Akka.Analyzers + + # Restore and build the project + dotnet restore + dotnet build +} +catch { + Write-Error "An error occurred: $_" +} +finally { + # Return to the original directory + Set-Location $originalDir +} diff --git a/test/Akka.Analyzers.NetFxInstallCanary/Akka.Analyzers.NetFxInstallCanary.csproj b/test/Akka.Analyzers.NetFxInstallCanary/Akka.Analyzers.NetFxInstallCanary.csproj new file mode 100644 index 0000000..3afe7b4 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/Akka.Analyzers.NetFxInstallCanary.csproj @@ -0,0 +1,54 @@ + + + + + Debug + AnyCPU + {13B048E3-D496-4F5E-BFF8-2305462171D1} + Exe + Properties + Akka.Analyzers.NetFxInstallCanary + Akka.Analyzers.NetFxInstallCanary + v4.8 + 512 + true + + + AnyCPU + true + full + false + bin\Debug\ + DEBUG;TRACE + prompt + 4 + + + AnyCPU + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + + + + + + + + + + + + diff --git a/test/Akka.Analyzers.NetFxInstallCanary/Directory.Build.props b/test/Akka.Analyzers.NetFxInstallCanary/Directory.Build.props new file mode 100644 index 0000000..c84d8de --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/Directory.Build.props @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/test/Akka.Analyzers.NetFxInstallCanary/Directory.Packages.props b/test/Akka.Analyzers.NetFxInstallCanary/Directory.Packages.props new file mode 100644 index 0000000..c416fb7 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/Directory.Packages.props @@ -0,0 +1,5 @@ + + + false + + \ No newline at end of file diff --git a/test/Akka.Analyzers.NetFxInstallCanary/Program.cs b/test/Akka.Analyzers.NetFxInstallCanary/Program.cs new file mode 100644 index 0000000..4e72725 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/Program.cs @@ -0,0 +1,9 @@ +namespace Akka.Analyzers.NetFxInstallCanary +{ + internal class Program + { + public static void Main(string[] args) + { + } + } +} \ No newline at end of file diff --git a/test/Akka.Analyzers.NetFxInstallCanary/Properties/AssemblyInfo.cs b/test/Akka.Analyzers.NetFxInstallCanary/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..c760402 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/Properties/AssemblyInfo.cs @@ -0,0 +1,35 @@ +using System.Reflection; +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("Akka.Analyzers.NetFxInstallCanary")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("Akka.Analyzers.NetFxInstallCanary")] +[assembly: AssemblyCopyright("Copyright © 2024")] +[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("13B048E3-D496-4F5E-BFF8-2305462171D1")] + +// 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")] \ No newline at end of file diff --git a/test/Akka.Analyzers.NetFxInstallCanary/README.md b/test/Akka.Analyzers.NetFxInstallCanary/README.md new file mode 100644 index 0000000..48a19d5 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/README.md @@ -0,0 +1,5 @@ +# NET Framework Install Canary + +This is a basic C# project running on .NET Framework 4.8. In our Windows build pipeline we are going to attempt to install Akka.Analyzers from its NuGet output. This install will fail until https://github.com/akkadotnet/akka.net/issues/7307 is resolved. + +Do not modify this project or do anything else with it. \ No newline at end of file diff --git a/test/Akka.Analyzers.NetFxInstallCanary/nuget.config b/test/Akka.Analyzers.NetFxInstallCanary/nuget.config new file mode 100644 index 0000000..08fff80 --- /dev/null +++ b/test/Akka.Analyzers.NetFxInstallCanary/nuget.config @@ -0,0 +1,17 @@ + + + + + + + + + + + + + + + + +