xamarin-macios/tests/introspection
Rolf Bjarne Kvinge d2788511b6
[dotnet] Use net5.0-[ios|tvos|watchos|macos] TargetFrameworks. (#9532)
* [dotnet] Set TargetPlatformSupported when the right TargetPlatformIdentifier is used.

* [dotnet] Generate a list of valid OS versions for each platform, and add it to the SupportedTargetPlatform item group.

The generated files: https://gist.github.com/rolfbjarne/765c4e4b38b1b017380c9378d9666317

* [dotnet] Define and set the default platform version if it's not set in the TargetFramework variable.

* [dotnet] Switch to using the new-style TargetFramework values.

This includes bumping spouliot/Touch.Unit to get new-style TargetFramework values for Touch.Client.

* spouliot/Touch.Unit@89afaf7 [Touch.Client] Use the right TargetFrameworks for watchOS and macOS as well. (#92)
* spouliot/Touch.Unit@fd0e576 [Touch.Client] Use the right TargetFrameworks. (#91)
* spouliot/Touch.Unit@40f47db [Touch.Client] Add a macOS and watchOS version for .NET. (#90)
* spouliot/Touch.Unit@1d4b8c0 Add .gitignore for NuGet.config and global.json. (#89)
* spouliot/Touch.Unit@49441f3 Call `mlaunch` instead of `mtouch` (#88)
* spouliot/Touch.Unit@b157cf4 Fix a few markdown issues found by markdownlint. (#87)

Diff: d7f55a6167..89afaf7e05

* [dotnet] Document the script that generates the lists of the target platform versions a little bit better.

* [dotnet] Make the [Platform]SupportedTargetPlatform variables public.

This matches how Android and Windows do it:

* https://github.com/xamarin/xamarin-android/pull/5007
* 18ee4eac8b/src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.WindowsSupportedTargetPlatforms.props

* [xharness] Update the TargetFramework value when creating project variations.
2020-08-31 09:27:19 +02:00
..
Mac [tests] Update Xamarin.Mac tests to use Touch.Client and the official NUnit[Lite]. 2020-08-03 11:53:17 +02:00
iOS [dotnet] Use net5.0-[ios|tvos|watchos|macos] TargetFrameworks. (#9532) 2020-08-31 09:27:19 +02:00
ApiAvailabilityTest.cs [master] Merge Xcode11.5 Support and include provisionator changes (#8643) 2020-05-21 12:16:33 -04:00
ApiBaseTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiCMAttachmentTest.cs [introspection] Disable tests that require crypto due to dotnet/runtime#36897 on .NET. 2020-06-30 19:01:07 +02:00
ApiClassPtrTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiCoreImageFiltersTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiCtorInitTest.cs [tests] Accommodate intro test to .NET 5 changes 2020-07-22 15:44:42 -04:00
ApiFieldTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiFrameworkTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiPInvokeTest.cs [introspection] Some P/Invokes have moved to a QCall library in .NET 5 preview 8+. (#9300) 2020-08-07 08:06:31 +02:00
ApiProtocolTest.cs [MetalPerformanceShaders] Neural Networks Update to Xcode 11 (#8844) 2020-07-22 15:44:42 -04:00
ApiSelectorTest.cs [MetalPerformanceShaders] Neural Networks Update to Xcode 11 (#8844) 2020-07-22 15:44:42 -04:00
ApiSignatureTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiStructTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
ApiTypeTest.cs [xcode11.4] [tests] Add `.cctor` execution to introspection (#7987) 2020-02-26 16:16:04 -05:00
ApiTypoTest.cs [MetalPerformanceShaders] Neural Networks Update to Xcode 11 (#8844) 2020-07-22 15:44:42 -04:00
ApiWeakPropertyTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
CoreSelectorTest.cs [introspection] Remove Classic code. (#8620) 2020-05-20 09:29:21 +02:00
EnvironmentVariable.cs Move parts of dontlink tests into new introspection tests (#32) 2016-05-04 20:14:32 -04:00
README.md [tests] Move linker tests from maccore (#69) 2016-05-20 14:07:34 -04:00
xamarin1.png Move parts of dontlink tests into new introspection tests (#32) 2016-05-04 20:14:32 -04:00

README.md

Introspection Tests

Introspection tests are executed on target (both simulator and device for iOS) or a specific version of OSX. The application proceed to analyze itself using:

  • System.Reflection for managed code; and
  • the ObjectiveC runtime library for native code

and compare the results. E.g. if using .NET reflection it can see a binding for a NSBundle type then it should be able to find a native NSBundle type using the ObjC runtime functions. Otherwise an error is raised...

Since the application analyze itself it must contains everything we wish to test. That's why the introspection tests needs to be built with the managed linker disable, i.e. "Don't link".

Pros

  • The tests always tell the truth, which can differ from documentation or header files;

Cons

  • Incomplete - Not everything is encoded in the metadata / executable;
  • Too complete - Not every truth is good to be known (or published), which requires creating special cases in the tests