-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Convert MonoVM Samples into Functional Tests #43865
Comments
- Included the ios sample project to the library test build. The sample still can be build/run locally using make file. - Added copying resulting HelloiOS.app to helix directory from where it can be consumed by CI. - Changed the sample to return 42 when building for CI, which is used as an expected exit code for xharness. - Xharness for iOS supports running an application on a simulator w/o test runner inside, the sample is run by this approach. - Checked locally that xharness can run HelloiOS.app successfully. Related issue: #43865
- Included the android sample project to the library test build. - Added copying resulting HelloAndroid.apk to helix test directory from where it can be consumed by CI. - Set up the return value (42) as an expected exit code for xharness. - Xharness for android doesn't support running an application w/o test runner yet Related issue: #43865
- Included the WASM console sample project to the library test build. The sample can still be built/run locally using make file. - Added zipping/copying the sample application to helix directory from where it can be consumed by CI. - To run on Helix, tried to use a simple helix work item which wouldn't rely on generated RunTests.sh and just call the xharness command directly. Relates to #43865
Part of #43865 The functional tests: - live under src/tests/FunctionalTests directory. - are built as a part of the library tests build. - are isolated from the build/test setup used for the tests in src/tests - run on CI
@marek-safar Could you please clarify or give some example of what in particular should be done here? |
@MaximLipnin we need tests for each configuration where the test calls unmanaged code via pinvoke. Something like class C
{
[DllImport ("somelib.dll")]
static void ExternalNativeAPI ();
public static void Main ()
{
int result = ExternalNativeAPI ();
// check result
}
} |
@MaximLipnin Please arrange the functional tests similar to how the tasks are listed in this issue. Also, with respect to |
Heads up: Once #47683 is merged, you might want to add these test projects as xunit tests. |
Contributes to #43865 ./build.sh mono+libs -os Android -arch x64 -c Release ./dotnet.sh build /t:Test src/tests/FunctionalTests/Android/Device_Emulator/InvariantCultureOnlyMode /p:TargetOS=Android /p:TargetArchitecture=x64 /p:Configuration=Release
Contributes to #43865 1. ./build.sh mono+libs -os iOS -arch x64 -c Release 2. ./dotnet.sh build /t:Test src/tests/FunctionalTests/iOS/Simulator/InvariantCultureOnlyMode /p:TargetOS=iOS /p:TargetArchitecture=x64 /p:Configuration=Release
Contributes to #43865. Based on https://github.com/xamarin/xamarin-macios/blob/834b0888853210ca01d5e8f5ce2c65fe9c55fc10/dotnet/targets/Xamarin.Shared.Sdk.targets#L138-L146 The changes: - added a property group with iOS/iOSSimulator default feature flags; - aligned the conditions to check the properties activating the defaults for true in order to follow better msbuild practice.
FYI, for wasm, we have tests for using native libraries, and for invariant culture mode, in |
@steveisok it sounds like the mono samples in this repo are still useful, do we still want to extract tests for iOS device? Either way it seems like this can either be closed or pushed to 8 |
The mono samples do a good job of showing off the platforms we support and often serve as a mini test bed. Unfortunately, they have a tendency to break over time and sometimes we'll be slow to realize it. To combat that, we should convert the samples into functional tests.
We will want to:
Integrate w/ XHarness
The text was updated successfully, but these errors were encountered: