Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1455,7 +1455,7 @@ because xbuild doesn't support framework reference assemblies.
</_GenerateJavaStubsDependsOnTargets>
</PropertyGroup>

<Target Name="_GetGenerateJavaStubsInputs">
<Target Name="_GetGenerateJavaStubsInputs" DependsOnTargets="_GenerateEnvironmentFiles">
<ItemGroup>
<_GenerateJavaStubsInputs Include="@(_AndroidMSBuildAllProjects)" />
<_GenerateJavaStubsInputs Include="$(_ResolvedUserAssembliesHashFile)" />
Expand Down Expand Up @@ -1616,7 +1616,7 @@ because xbuild doesn't support framework reference assemblies.
</PrepareAbiItems>
</Target>

<Target Name="_GenerateEnvironmentFiles" DependsOnTargets="_ReadAndroidManifest">
<Target Name="_GenerateEnvironmentFiles">
<ItemGroup>
<_GeneratedAndroidEnvironment Include="__XA_PACKAGE_NAMING_POLICY__=$(AndroidPackageNamingPolicy)" />
<_GeneratedAndroidEnvironment Include="mono.enable_assembly_preload=0" Condition=" '$(AndroidEnablePreloadAssemblies)' != 'True' " />
Expand Down
10 changes: 9 additions & 1 deletion tests/MSBuildDeviceIntegration/Tests/InstallAndRunTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -951,12 +951,20 @@ public void SupportDesugaringStaticInterfaceMethods ()
}

[Test]
public void FastDeployEnvironmentFiles ([Values (false, true)] bool isRelease)
[TestCase (false, true)]
[TestCase (false, false)]
[TestCase (true, false)]
public void FastDeployEnvironmentFiles (bool isRelease, bool embedAssembliesIntoApk)
{
if (embedAssembliesIntoApk) {
AssertCommercialBuild ();
}

var proj = new XamarinAndroidApplicationProject {
ProjectName = nameof (FastDeployEnvironmentFiles),
RootNamespace = nameof (FastDeployEnvironmentFiles),
IsRelease = isRelease,
EmbedAssembliesIntoApk = embedAssembliesIntoApk,
EnableDefaultItems = true,
OtherBuildItems = {
new BuildItem("AndroidEnvironment", "env.txt") {
Expand Down
Loading