diff --git a/ComputeSharp.sln b/ComputeSharp.sln index 97cfd4ee..1f3e2fa9 100644 --- a/ComputeSharp.sln +++ b/ComputeSharp.sln @@ -150,6 +150,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Assets", "Assets", "{345F62 assets\icon_highres.png = assets\icon_highres.png EndProjectSection EndProject +Project("{D954291E-2A0B-460D-934E-DC6B0785DB48}") = "ComputeSharp.D2D1.UI.Tests", "tests\ComputeSharp.D2D1.UI.Tests\ComputeSharp.D2D1.UI.Tests.shproj", "{346AEB10-A4EA-427E-8578-F60915DB3053}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ComputeSharp.D2D1.Uwp.Tests", "tests\ComputeSharp.D2D1.Uwp.Tests\ComputeSharp.D2D1.Uwp.Tests.csproj", "{4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|x64 = Debug|x64 @@ -414,6 +418,18 @@ Global {9EA5AE9D-C39A-4F43-B03E-0A848EA2558A}.Release|ARM64.Build.0 = Release|ARM64 {9EA5AE9D-C39A-4F43-B03E-0A848EA2558A}.Release|x64.ActiveCfg = Release|x64 {9EA5AE9D-C39A-4F43-B03E-0A848EA2558A}.Release|x64.Build.0 = Release|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|ARM64.ActiveCfg = Debug|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|ARM64.Build.0 = Debug|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|ARM64.Deploy.0 = Debug|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|x64.ActiveCfg = Debug|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|x64.Build.0 = Debug|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Debug|x64.Deploy.0 = Debug|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|ARM64.ActiveCfg = Release|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|ARM64.Build.0 = Release|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|ARM64.Deploy.0 = Release|ARM64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|x64.ActiveCfg = Release|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|x64.Build.0 = Release|x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3}.Release|x64.Deploy.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -451,6 +467,8 @@ Global {568E7009-5C13-4153-9C94-0AC7A3E6883C} = {1A9C4108-F61A-4ABE-B5CF-F524521EAE2D} {B54B6DCA-6EAB-46A8-83D3-15154659F47F} = {1A9C4108-F61A-4ABE-B5CF-F524521EAE2D} {9EA5AE9D-C39A-4F43-B03E-0A848EA2558A} = {0ED8F632-5E17-46BE-8CC3-B14A82D4AEB1} + {346AEB10-A4EA-427E-8578-F60915DB3053} = {F8EFBB27-4EE2-4463-A75B-7EFDFB55D0F7} + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3} = {F8EFBB27-4EE2-4463-A75B-7EFDFB55D0F7} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {4664C5E3-0340-4E22-BCFD-98AAEDF5F2DC} @@ -464,6 +482,7 @@ Global src\TerraFX.Interop.Windows.Dynamic\TerraFX.Interop.Windows.Dynamic.projitems*{158f984d-cd96-4062-bd02-2268946031a0}*SharedItemsImports = 13 samples\ComputeSharp.SwapChain.Shaders.D2D1.Shared\ComputeSharp.SwapChain.Shaders.D2D1.Shared.projitems*{209c95a3-fa53-431b-b688-3299ca6c29d2}*SharedItemsImports = 5 src\TerraFX.Interop.Windows\TerraFX.Interop.Windows.projitems*{314eb353-e7e3-4146-8111-685cc83ec1de}*SharedItemsImports = 5 + tests\ComputeSharp.D2D1.UI.Tests\ComputeSharp.D2D1.UI.Tests.projitems*{346aeb10-a4ea-427e-8578-f60915db3053}*SharedItemsImports = 13 src\TerraFX.Interop.Windows.D2D1\TerraFX.Interop.Windows.D2D1.projitems*{4d7d9ba8-a821-4b1c-9ee2-cbcf5849906e}*SharedItemsImports = 5 src\TerraFX.Interop.Windows\TerraFX.Interop.Windows.projitems*{514ff00e-bbf0-4d55-a47c-eeeb6208adce}*SharedItemsImports = 13 src\ComputeSharp.SourceGeneration\ComputeSharp.SourceGeneration.projitems*{51d5a422-d3a5-4c4d-8a6d-a048940bf279}*SharedItemsImports = 13 diff --git a/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.projitems b/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.projitems new file mode 100644 index 00000000..b7d37ed3 --- /dev/null +++ b/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.projitems @@ -0,0 +1,13 @@ + + + + $(MSBuildAllProjects);$(MSBuildThisFileFullPath) + true + 346aeb10-a4ea-427e-8578-f60915db3053 + + + ComputeSharp.D2D1.UI.Tests + + + + diff --git a/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.shproj b/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.shproj new file mode 100644 index 00000000..9abf6f55 --- /dev/null +++ b/tests/ComputeSharp.D2D1.UI.Tests/ComputeSharp.D2D1.UI.Tests.shproj @@ -0,0 +1,13 @@ + + + + 346aeb10-a4ea-427e-8578-f60915db3053 + 14.0 + + + + + + + + diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/LockScreenLogo.scale-200.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/LockScreenLogo.scale-200.png new file mode 100644 index 00000000..735f57ad Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/LockScreenLogo.scale-200.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/SplashScreen.scale-200.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/SplashScreen.scale-200.png new file mode 100644 index 00000000..023e7f1f Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/SplashScreen.scale-200.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square150x150Logo.scale-200.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square150x150Logo.scale-200.png new file mode 100644 index 00000000..af49fec1 Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square150x150Logo.scale-200.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.scale-200.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.scale-200.png new file mode 100644 index 00000000..ce342a2e Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.scale-200.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.targetsize-24_altform-unplated.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.targetsize-24_altform-unplated.png new file mode 100644 index 00000000..f6c02ce9 Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Square44x44Logo.targetsize-24_altform-unplated.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/StoreLogo.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/StoreLogo.png new file mode 100644 index 00000000..7385b56c Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/StoreLogo.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Wide310x150Logo.scale-200.png b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Wide310x150Logo.scale-200.png new file mode 100644 index 00000000..288995b3 Binary files /dev/null and b/tests/ComputeSharp.D2D1.Uwp.Tests/Assets/Wide310x150Logo.scale-200.png differ diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/ComputeSharp.D2D1.Uwp.Tests.csproj b/tests/ComputeSharp.D2D1.Uwp.Tests/ComputeSharp.D2D1.Uwp.Tests.csproj new file mode 100644 index 00000000..daae7b31 --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/ComputeSharp.D2D1.Uwp.Tests.csproj @@ -0,0 +1,117 @@ + + + + + Debug + x64 + {4D4BB2F6-5653-4DB5-A8DD-90D58D8FE4D3} + AppContainerExe + Properties + ComputeSharp.D2D1.Uwp.Tests + ComputeSharp.D2D1.Uwp.Tests + en-US + UAP + 10.0.22621.0 + 10.0.17763.0 + 14 + 512 + {A5A43C5B-DE2A-4C0C-9213-0A381AF9435A};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC} + $(VisualStudioVersion) + false + + + true + bin\ARM64\Debug\ + DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP + ;2008 + full + ARM64 + false + prompt + true + true + + + bin\ARM64\Release\ + TRACE;NETFX_CORE;WINDOWS_UWP + true + ;2008 + pdbonly + ARM64 + false + prompt + true + true + + + true + bin\x64\Debug\ + DEBUG;TRACE;NETFX_CORE;WINDOWS_UWP + ;2008 + full + x64 + false + prompt + true + + + bin\x64\Release\ + TRACE;NETFX_CORE;WINDOWS_UWP + true + ;2008 + pdbonly + x64 + false + prompt + true + true + + + PackageReference + + + + + + + + UnitTestApp.xaml + + + + + MSBuild:Compile + Designer + + + + + Designer + + + + + + + + + + + + + + + 6.2.14 + + + 2.2.7 + + + 2.2.7 + + + + 14.0 + + + \ No newline at end of file diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Package.appxmanifest b/tests/ComputeSharp.D2D1.Uwp.Tests/Package.appxmanifest new file mode 100644 index 00000000..24fb011e --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/Package.appxmanifest @@ -0,0 +1,44 @@ + + + + + + + + + ComputeSharp.D2D1.Uwp.Tests + sergiopedri + Assets\StoreLogo.png + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/AssemblyInfo.cs b/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..8fb8814e --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/AssemblyInfo.cs @@ -0,0 +1,16 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; + +[assembly: AssemblyTitle("ComputeSharp.D2D1.Uwp.Tests")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("ComputeSharp.D2D1.Uwp.Tests")] +[assembly: AssemblyCopyright("Copyright © 2023")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] +[assembly: AssemblyMetadata("TargetPlatform","UAP")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] +[assembly: ComVisible(false)] \ No newline at end of file diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/Default.rd.xml b/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/Default.rd.xml new file mode 100644 index 00000000..922d306f --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/Properties/Default.rd.xml @@ -0,0 +1,22 @@ + + + + + + + \ No newline at end of file diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml b/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml new file mode 100644 index 00000000..606340e6 --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml @@ -0,0 +1,4 @@ + diff --git a/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml.cs b/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml.cs new file mode 100644 index 00000000..0f6c05d2 --- /dev/null +++ b/tests/ComputeSharp.D2D1.Uwp.Tests/UnitTestApp.xaml.cs @@ -0,0 +1,31 @@ +using Windows.ApplicationModel.Activation; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; + +namespace ComputeSharp.D2D1.Uwp.Tests; + +/// +/// Provides application-specific behavior to supplement the default Application class. +/// +public sealed partial class App : Application +{ + /// + /// Creates a new instance. + /// + public App() + { + InitializeComponent(); + } + + /// + protected override void OnLaunched(LaunchActivatedEventArgs e) + { + Window.Current.Content ??= new Frame(); + + Microsoft.VisualStudio.TestPlatform.TestExecutor.UnitTestClient.CreateDefaultUI(); + + Window.Current.Activate(); + + Microsoft.VisualStudio.TestPlatform.TestExecutor.UnitTestClient.Run(e.Arguments); + } +} \ No newline at end of file