xamarin-macios/tests/introspection
Rolf Bjarne Kvinge 305ecde2cd
[tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098)
Co-authored-by: Alex Soto <alex@alexsoto.me>
2022-02-09 08:26:37 +01:00
..
Mac [tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098) 2022-02-09 08:26:37 +01:00
dotnet [xharness] Inline the dotnet-shared.csproj file as well when inlining shared imports. (#13514) 2021-12-16 19:01:39 +01:00
iOS [tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098) 2022-02-09 08:26:37 +01:00
ApiAvailabilityTest.cs [tests] Disable attribute duplication check (#13745) 2022-01-18 09:07:43 -06:00
ApiBaseTest.cs [tests][intro] Fix Phase tests on macOS 12 and iOS devices (#12376) 2021-08-06 16:28:04 -04:00
ApiCMAttachmentTest.cs [CFNetwork] Move the CFHost and CFHTTP* types to the CFNetwork namespace in .NET. (#13761) 2022-01-19 08:07:06 +01:00
ApiClassPtrTest.cs [tests][introspection] A few test updates according to the API changes 2021-11-26 14:25:21 +01:00
ApiCoreImageFiltersTest.cs [CoreImage] Adopt XAMCORE_4_0 changes in .NET. (#13983) 2022-02-02 16:07:45 +01:00
ApiCtorInitTest.cs [tools] HomeKit was added to Mac Catalyst in 14.0, so mark it as such. (#13333) 2021-11-15 08:04:56 +01:00
ApiFieldTest.cs [xcode13] Bump PR to Xcode 13 Beta 2 (#12017) 2021-06-28 17:54:52 -04:00
ApiFrameworkTest.cs [Foundation] Remove a WebKit workaround for NSProxy on tvOS in .NET. (#14089) 2022-02-08 10:48:40 +01:00
ApiPInvokeTest.cs [introspection] Skip verifying the objc_msgSend[Super]_stret on all platforms. (#12939) 2021-10-07 20:15:54 +02:00
ApiProtocolTest.cs [tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098) 2022-02-09 08:26:37 +01:00
ApiSelectorTest.cs [tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098) 2022-02-09 08:26:37 +01:00
ApiSignatureTest.cs [tests][introspection] A few test updates according to the API changes 2021-11-26 14:25:21 +01:00
ApiStructTest.cs Fix some whitespace issues in various files. (#12399) 2021-08-11 10:06:46 +02:00
ApiTypeTest.cs [dotnet] Remove Runtime.Arch and ObjCRuntime.Arch from Mac Catalyst. Fixes #10312. (#13562) 2021-12-15 22:32:14 +01:00
ApiTypoTest.cs [tests] Adopt XAMCORE_4_0 changes for introspection in .NET. (#14098) 2022-02-09 08:26:37 +01:00
ApiWeakPropertyTest.cs Fix some whitespace issues in various files. (#12399) 2021-08-11 10:06:46 +02:00
CoreSelectorTest.cs [xcode12] Introspection-based fixes for Big Sur (#9632) 2020-09-15 08:56:24 -04: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