Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[tests] add test for Microsoft.Intune #7926

Merged
merged 4 commits into from
Nov 2, 2023

Conversation

jonathanpeppers
Copy link
Member

Context: https://www.nuget.org/packages/Microsoft.Intune.Maui.Essentials.android/9.5.2-beta

The Microsoft.Intune.Maui.Essentials.android makes use of specific MSBuild targets and "remapping" features.

We should add a test verifying that it stays working over time.

@jonathanpeppers
Copy link
Member Author

Test fails with:

error MSB4057: The target "_IntuneDependsOnFixup" does not exist in the project.

Microsoft.Intune.Maui.Essentials.android.targets has:

<Project InitialTargets="_IntuneDependsOnFixup">

@jonathanpeppers
Copy link
Member Author

Latest appears to attempt to run a .bat file on Mac:

(_IntuneMamifyForXamarinRemapping target) -> 
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error : An error occurred trying to start process '/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/BuildTool\bin\BuildToolCLI.bat' with working directory '/Users/runner/work/1/a/TestRelease/04-26_16.41.34/temp/MicrosoftIntuneFalse'. No such file or directory
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error :    at System.Diagnostics.Process.ForkAndExecProcess(ProcessStartInfo startInfo, String resolvedFilename, String[] argv, String[] envp, String cwd, Boolean setCredentials, UInt32 userId, UInt32 groupId, UInt32[] groups, Int32& stdinFd, Int32& stdoutFd, Int32& stderrFd, Boolean usesTerminal, Boolean throwOnNoExec)
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error :    at System.Diagnostics.Process.StartCore(ProcessStartInfo startInfo)
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error :    at Core.BuildToolCLI.ExecuteBuildToolCLIProcess(Argument input, Argument output, Argument classpath, Argument excludeClasses, Argument reportPath, String workingDirectory, CancellationToken cancellationToken)
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error :    at Core.Mamifier.Mamify()
/Users/runner/.nuget/packages/microsoft.intune.maui.essentials.android/9.5.2-beta2/build/netstandard2.0/Microsoft.Intune.Maui.Essentials.android.targets(287,9): error :    at BuildTasks.MamifyFiles.Execute()

Context: https://www.nuget.org/packages/Microsoft.Intune.Maui.Essentials.android/9.5.2-beta

The `Microsoft.Intune.Maui.Essentials.android` makes use of specific
MSBuild targets and "remapping" features.

We should add a test verifying that it stays working over time.
Have to use a valid AppCompat theme.
@jonathanpeppers
Copy link
Member Author

New test passes:

image

@jonathanpeppers jonathanpeppers merged commit 0808d18 into dotnet:main Nov 2, 2023
47 checks passed
@jonathanpeppers jonathanpeppers deleted the MicrosoftIntune branch November 2, 2023 20:34
grendello added a commit that referenced this pull request Nov 3, 2023
* main:
  [tests] add test for Microsoft.Intune (#7926)
jonathanpeppers added a commit that referenced this pull request Nov 30, 2023
Context: https://www.nuget.org/packages/Microsoft.Intune.Maui.Essentials.android/9.5.2-beta

The `Microsoft.Intune.Maui.Essentials.android` makes use of specific
MSBuild targets and "remapping" features.

We should add a test verifying that it stays working over time.

Assert `MainActivity.onMAMCreate` exists in `classes.dex`, to verify this package actually
"does something". Otherwise, the test would just pass if we removed
the Intune package.
@github-actions github-actions bot locked and limited conversation to collaborators Jan 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants