forked from xamarin/xamarin-macios
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[dotnet] Implement resource bundling. (xamarin#9472)
* Port the BundledResources test to .NET. * Fix a minor issue in the BundledResources test to make sure it works on macOS. * Add a unit test to make sure resources are bundled as expected. * Modify the .NET build logic to bundle/unbundle resources.
- Loading branch information
1 parent
18ca278
commit ab47edc
Showing
7 changed files
with
134 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project Sdk="Microsoft.iOS.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net5.0</TargetFramework> | ||
<LangVersion>latest</LangVersion> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="NUnitLite" Version="3.12.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<BundleResource Include="..\..\..\monotouch-test\basn3p08.png"> | ||
<Link>basn3p08.png</Link> | ||
</BundleResource> | ||
<BundleResource Include="..\..\..\monotouch-test\xamvideotest.mp4"> | ||
<Link>xamvideotest.mp4</Link> | ||
</BundleResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\ResourcesTest.cs" /> | ||
</ItemGroup> | ||
</Project> |
23 changes: 23 additions & 0 deletions
23
tests/BundledResources/dotnet/macOS/BundledResources.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project Sdk="Microsoft.macOS.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net5.0</TargetFramework> | ||
<LangVersion>latest</LangVersion> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="NUnitLite" Version="3.12.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<BundleResource Include="..\..\..\monotouch-test\basn3p08.png"> | ||
<Link>basn3p08.png</Link> | ||
</BundleResource> | ||
<BundleResource Include="..\..\..\monotouch-test\xamvideotest.mp4"> | ||
<Link>xamvideotest.mp4</Link> | ||
</BundleResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\ResourcesTest.cs" /> | ||
</ItemGroup> | ||
</Project> |
23 changes: 23 additions & 0 deletions
23
tests/BundledResources/dotnet/tvOS/BundledResources.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project Sdk="Microsoft.tvOS.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net5.0</TargetFramework> | ||
<LangVersion>latest</LangVersion> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="NUnitLite" Version="3.12.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<BundleResource Include="..\..\..\monotouch-test\basn3p08.png"> | ||
<Link>basn3p08.png</Link> | ||
</BundleResource> | ||
<BundleResource Include="..\..\..\monotouch-test\xamvideotest.mp4"> | ||
<Link>xamvideotest.mp4</Link> | ||
</BundleResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\ResourcesTest.cs" /> | ||
</ItemGroup> | ||
</Project> |
23 changes: 23 additions & 0 deletions
23
tests/BundledResources/dotnet/watchOS/BundledResources.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project Sdk="Microsoft.watchOS.Sdk"> | ||
<PropertyGroup> | ||
<TargetFramework>net5.0</TargetFramework> | ||
<LangVersion>latest</LangVersion> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="NUnitLite" Version="3.12.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<BundleResource Include="..\..\..\monotouch-test\basn3p08.png"> | ||
<Link>basn3p08.png</Link> | ||
</BundleResource> | ||
<BundleResource Include="..\..\..\monotouch-test\xamvideotest.mp4"> | ||
<Link>xamvideotest.mp4</Link> | ||
</BundleResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="..\..\ResourcesTest.cs" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters