xamarin-macios/tests/introspection
Alex Soto db0b1ff52f Merge remote-tracking branch 'xamarin/main' into net8.0-main-merge 2023-04-05 15:25:09 -04:00
..
Mac Merge main into net8.0. 2023-02-17 14:58:12 +01:00
dotnet [tests] Unify code related to how to load test assemblies. (#17111) 2023-01-13 22:20:47 +01:00
iOS Merge remote-tracking branch 'xamarin/main' into net8.0-main-merge 2023-04-05 15:25:09 -04:00
ApiAvailabilityTest.cs [tests] Port and improve the availability attribute test from introspection. (#17083) 2022-12-20 12:46:06 +01:00
ApiBaseTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiCMAttachmentTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiClassPtrTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiCoreImageFiltersTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiCtorInitTest.cs Add ventura to mac tests configurations (#17349) 2023-02-13 11:08:18 -05:00
ApiFieldTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiFrameworkTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiPInvokeTest.cs [tools/tests] Remove the Compat option for the MonoNative library. 2023-02-02 16:30:29 +01:00
ApiProtocolTest.cs [xcode14.3] Update bidnings to Xcode 14.3 RC and fix tests 2023-03-29 14:37:51 -04:00
ApiSelectorTest.cs [xcode14.3] Update bidnings to Xcode 14.3 RC and fix tests 2023-03-29 14:37:51 -04:00
ApiSignatureTest.cs [runtime/generator] Add support for BindAs with CMVideoDimensions. (#17308) 2023-01-25 15:34:28 +01:00
ApiStructTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiTypeTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01:00
ApiTypoTest.cs Add ventura to mac tests configurations (#17349) 2023-02-13 11:08:18 -05:00
ApiWeakPropertyTest.cs [AppKit] Add a weakly typed version of NSRulerView.WeakMeasurementUnits. Fixes #17742. (#17779) 2023-03-15 10:47:11 +01:00
CoreSelectorTest.cs [autoformat] Add introspection. (#16593) 2022-11-07 15:20:26 +01: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