@@ -129,7 +129,7 @@ public async Task PolymorphicClass_AllowOutOfOrderMetadata_RejectsInvalidInputs(
129129
130130 //--
131131
132- [ Theory ]
132+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
133133 [ MemberData ( nameof ( Get_PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Serialization ) ) ]
134134 public Task PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Serialization ( PolymorphicClass . TestData testData )
135135 => TestMultiContextSerialization (
@@ -142,7 +142,7 @@ public Task PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Serializa
142142 public static IEnumerable < object [ ] > Get_PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Serialization ( )
143143 => PolymorphicClass . GetSerializeTestData_CustomConfigWithBaseTypeFallback ( ) . Select ( entry => new object [ ] { entry } ) ;
144144
145- [ Theory ]
145+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
146146 [ MemberData ( nameof ( Get_PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Deserialization ) ) ]
147147 public Task PolymorphicClass_CustomConfigWithBaseTypeFallback_TestData_Deserialization ( PolymorphicClass . TestData testData )
148148 => TestMultiContextDeserialization < PolymorphicClass > (
@@ -157,7 +157,7 @@ public static IEnumerable<object[]> Get_PolymorphicClass_CustomConfigWithBaseTyp
157157 . Where ( entry => entry . ExpectedJson != null )
158158 . Select ( entry => new object [ ] { entry } ) ;
159159
160- [ Fact ]
160+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
161161 public async Task PolymorphicClass_CustomConfigWithBaseTypeFallback_TestDataArray_Serialization ( )
162162 {
163163 IEnumerable < ( PolymorphicClass Value , string ExpectedJson ) > inputs =
@@ -168,7 +168,7 @@ public async Task PolymorphicClass_CustomConfigWithBaseTypeFallback_TestDataArra
168168 await TestMultiContextSerialization ( inputs , options : PolymorphicClass . CustomConfigWithBaseTypeFallback ) ;
169169 }
170170
171- [ Fact ]
171+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
172172 public async Task PolymorphicClass_CustomConfigWithBaseTypeFallbacks_TestDataArray_Deserialization ( )
173173 {
174174 IEnumerable < ( string ExpectedJson , PolymorphicClass ExpectedRoundtripValue ) > inputs =
@@ -182,7 +182,7 @@ await TestMultiContextDeserialization(
182182 options : PolymorphicClass . CustomConfigWithBaseTypeFallback ) ;
183183 }
184184
185- [ Theory ]
185+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
186186 [ InlineData ( "$['$type']" , """{ "$type" : "derivedClass1", "Number" : 42 }""" ) ]
187187 [ InlineData ( "$._case" , """{ "_case" : "derivedClass1", "_case" : "derivedClass1", "Number" : 42 }""" ) ]
188188 [ InlineData ( "$._case" , """{ "_case" : "derivedClass1", "Number" : 42, "_case" : "derivedClass1"}""" ) ]
@@ -206,7 +206,7 @@ public async Task PolymorphicClass_CustomConfigWithBaseTypeFallback_InvalidTypeD
206206
207207 //---
208208
209- [ Theory ]
209+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
210210 [ MemberData ( nameof ( Get_PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Serialization ) ) ]
211211 public Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Serialization ( PolymorphicClass . TestData testData )
212212 => TestMultiContextSerialization (
@@ -219,7 +219,7 @@ public Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Se
219219 public static IEnumerable < object [ ] > Get_PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Serialization ( )
220220 => PolymorphicClass . GetSerializeTestData_CustomConfigWithNearestAncestorFallback ( ) . Select ( entry => new object [ ] { entry } ) ;
221221
222- [ Theory ]
222+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
223223 [ MemberData ( nameof ( Get_PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Deserialization ) ) ]
224224 public Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestData_Deserialization ( PolymorphicClass . TestData testData )
225225 => TestMultiContextDeserialization < PolymorphicClass > (
@@ -234,7 +234,7 @@ public static IEnumerable<object[]> Get_PolymorphicClass_CustomConfigWithNearest
234234 . Where ( entry => entry . ExpectedJson != null )
235235 . Select ( entry => new object [ ] { entry } ) ;
236236
237- [ Fact ]
237+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
238238 public async Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestDataArray_Serialization ( )
239239 {
240240 IEnumerable < ( PolymorphicClass Value , string ExpectedJson ) > inputs =
@@ -245,7 +245,7 @@ public async Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestD
245245 await TestMultiContextSerialization ( inputs , options : PolymorphicClass . CustomConfigWithNearestAncestorFallback ) ;
246246 }
247247
248- [ Fact ]
248+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
249249 public async Task PolymorphicClass_CustomConfigWithNearestAncestorFallback_TestDataArray_Deserialization ( )
250250 {
251251 IEnumerable < ( string ExpectedJson , PolymorphicClass ExpectedRoundtripValue ) > inputs =
@@ -259,7 +259,7 @@ await TestMultiContextDeserialization(
259259 options : PolymorphicClass . CustomConfigWithNearestAncestorFallback ) ;
260260 }
261261
262- [ Theory ]
262+ [ ConditionalTheory ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
263263 [ InlineData ( "$['$type']" , """{ "$type" : "derivedClass1", "Number" : 42 }""" ) ]
264264 [ InlineData ( "$._case" , """{ "_case" : "derivedClass1", "_case" : "derivedClass1", "Number" : 42 }""" ) ]
265265 [ InlineData ( "$._case" , """{ "_case" : "derivedClass1", "Number" : 42, "_case" : "derivedClass1"}""" ) ]
@@ -1944,7 +1944,7 @@ public static IEnumerable<TestData> GetSerializeTestData()
19441944 public record TestData ( PolymorphicDictionary Value , string ExpectedJson , PolymorphicDictionary ExpectedRoundtripValue ) ;
19451945 }
19461946
1947- [ Fact ]
1947+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
19481948 public async Task PolymorphicDictionaryInterface_Serialization ( )
19491949 {
19501950 var values = new IEnumerable < KeyValuePair < int , object > > [ ]
@@ -1968,7 +1968,7 @@ public async Task PolymorphicDictionaryInterface_Serialization()
19681968 JsonTestHelper . AssertJsonEqual ( expectedJson , actualJson ) ;
19691969 }
19701970
1971- [ Fact ]
1971+ [ ConditionalFact ( typeof ( PlatformDetection ) , nameof ( PlatformDetection . IsNotNativeAot ) ) ]
19721972 public async Task PolymorphicDictionaryInterface_Deserialization ( )
19731973 {
19741974 string json =
0 commit comments