|
8 | 8 | namespace System.Text.Json.SourceGeneration.Tests |
9 | 9 | { |
10 | 10 | [JsonSerializable(typeof(Location))] |
11 | | - [JsonSerializable(typeof(RepeatedTypes.Location), TypeInfoPropertyName = "RepeatedLocation")] |
12 | | - [JsonSerializable(typeof(NumberTypes))] |
13 | | - [JsonSerializable(typeof(ActiveOrUpcomingEvent))] |
14 | | - [JsonSerializable(typeof(CampaignSummaryViewModel))] |
15 | | - [JsonSerializable(typeof(IndexViewModel))] |
16 | | - [JsonSerializable(typeof(WeatherForecastWithPOCOs))] |
17 | | - [JsonSerializable(typeof(EmptyPoco))] |
18 | | - // Ensure no errors when type of member in previously specified object graph is passed as input type to generator. |
19 | | - [JsonSerializable(typeof(HighLowTemps))] |
20 | | - [JsonSerializable(typeof(MyType))] |
21 | | - [JsonSerializable(typeof(MyType2))] |
22 | | - [JsonSerializable(typeof(MyTypeWithCallbacks))] |
23 | | - [JsonSerializable(typeof(MyTypeWithPropertyOrdering))] |
24 | | - [JsonSerializable(typeof(MyIntermediateType))] |
25 | | - [JsonSerializable(typeof(HighLowTempsImmutable))] |
26 | | - [JsonSerializable(typeof(HighLowTempsRecord))] |
27 | | - [JsonSerializable(typeof(byte[]))] |
28 | | - [JsonSerializable(typeof(RealWorldContextTests.MyNestedClass))] |
29 | | - [JsonSerializable(typeof(RealWorldContextTests.MyNestedClass.MyNestedNestedClass))] |
30 | | - [JsonSerializable(typeof(object[]))] |
31 | | - [JsonSerializable(typeof(string))] |
32 | | - [JsonSerializable(typeof((string Label1, int Label2, bool)))] |
33 | | - [JsonSerializable(typeof(JsonDocument))] |
34 | | - [JsonSerializable(typeof(JsonElement))] |
35 | | - [JsonSerializable(typeof(RealWorldContextTests.ClassWithEnumAndNullable))] |
36 | | - [JsonSerializable(typeof(RealWorldContextTests.ClassWithNullableProperties))] |
37 | | -#if NET |
38 | | - [JsonSerializable(typeof(RealWorldContextTests.ClassWithDateOnlyAndTimeOnlyValues))] |
39 | | -#endif |
40 | | - [JsonSerializable(typeof(ClassWithCustomConverter))] |
41 | | - [JsonSerializable(typeof(StructWithCustomConverter))] |
42 | | - [JsonSerializable(typeof(ClassWithCustomConverterFactory))] |
43 | | - [JsonSerializable(typeof(StructWithCustomConverterFactory))] |
44 | | - [JsonSerializable(typeof(ClassWithCustomConverterProperty))] |
45 | | - [JsonSerializable(typeof(StructWithCustomConverterProperty))] |
46 | | - [JsonSerializable(typeof(ClassWithCustomConverterFactoryProperty))] |
47 | | - [JsonSerializable(typeof(StructWithCustomConverterFactoryProperty))] |
48 | | - [JsonSerializable(typeof(ClassWithCustomConverterNullableProperty))] |
49 | | - [JsonSerializable(typeof(ClassWithCustomConverterFactoryNullableProperty))] |
50 | | - [JsonSerializable(typeof(ClassWithBadCustomConverter))] |
51 | | - [JsonSerializable(typeof(StructWithBadCustomConverter))] |
52 | | - [JsonSerializable(typeof(PersonStruct?))] |
53 | | - [JsonSerializable(typeof(TypeWithValidationAttributes))] |
54 | | - [JsonSerializable(typeof(TypeWithDerivedAttribute))] |
55 | | - [JsonSerializable(typeof(PolymorphicClass))] |
56 | | - [JsonSerializable(typeof(PocoWithNumberHandlingAttr))] |
57 | | - [JsonSerializable(typeof(PocoWithMixedVisibilityMembers))] |
| 11 | +// [JsonSerializable(typeof(RepeatedTypes.Location), TypeInfoPropertyName = "RepeatedLocation")] |
| 12 | +// [JsonSerializable(typeof(NumberTypes))] |
| 13 | +// [JsonSerializable(typeof(ActiveOrUpcomingEvent))] |
| 14 | +// [JsonSerializable(typeof(CampaignSummaryViewModel))] |
| 15 | +// [JsonSerializable(typeof(IndexViewModel))] |
| 16 | +// [JsonSerializable(typeof(WeatherForecastWithPOCOs))] |
| 17 | +// [JsonSerializable(typeof(EmptyPoco))] |
| 18 | +// // Ensure no errors when type of member in previously specified object graph is passed as input type to generator. |
| 19 | +// [JsonSerializable(typeof(HighLowTemps))] |
| 20 | +// [JsonSerializable(typeof(MyType))] |
| 21 | +// [JsonSerializable(typeof(MyType2))] |
| 22 | +// [JsonSerializable(typeof(MyTypeWithCallbacks))] |
| 23 | +// [JsonSerializable(typeof(MyTypeWithPropertyOrdering))] |
| 24 | +// [JsonSerializable(typeof(MyIntermediateType))] |
| 25 | +// [JsonSerializable(typeof(HighLowTempsImmutable))] |
| 26 | +// [JsonSerializable(typeof(HighLowTempsRecord))] |
| 27 | +// [JsonSerializable(typeof(byte[]))] |
| 28 | +// [JsonSerializable(typeof(RealWorldContextTests.MyNestedClass))] |
| 29 | +// [JsonSerializable(typeof(RealWorldContextTests.MyNestedClass.MyNestedNestedClass))] |
| 30 | +// [JsonSerializable(typeof(object[]))] |
| 31 | +// [JsonSerializable(typeof(string))] |
| 32 | +// [JsonSerializable(typeof((string Label1, int Label2, bool)))] |
| 33 | +// [JsonSerializable(typeof(JsonDocument))] |
| 34 | +// [JsonSerializable(typeof(JsonElement))] |
| 35 | +// [JsonSerializable(typeof(RealWorldContextTests.ClassWithEnumAndNullable))] |
| 36 | +// [JsonSerializable(typeof(RealWorldContextTests.ClassWithNullableProperties))] |
| 37 | +//#if NET |
| 38 | +// [JsonSerializable(typeof(RealWorldContextTests.ClassWithDateOnlyAndTimeOnlyValues))] |
| 39 | +//#endif |
| 40 | +// [JsonSerializable(typeof(ClassWithCustomConverter))] |
| 41 | +// [JsonSerializable(typeof(StructWithCustomConverter))] |
| 42 | +// [JsonSerializable(typeof(ClassWithCustomConverterFactory))] |
| 43 | +// [JsonSerializable(typeof(StructWithCustomConverterFactory))] |
| 44 | +// [JsonSerializable(typeof(ClassWithCustomConverterProperty))] |
| 45 | +// [JsonSerializable(typeof(StructWithCustomConverterProperty))] |
| 46 | +// [JsonSerializable(typeof(ClassWithCustomConverterFactoryProperty))] |
| 47 | +// [JsonSerializable(typeof(StructWithCustomConverterFactoryProperty))] |
| 48 | +// [JsonSerializable(typeof(ClassWithCustomConverterNullableProperty))] |
| 49 | +// [JsonSerializable(typeof(ClassWithCustomConverterFactoryNullableProperty))] |
| 50 | +// [JsonSerializable(typeof(ClassWithBadCustomConverter))] |
| 51 | +// [JsonSerializable(typeof(StructWithBadCustomConverter))] |
| 52 | +// [JsonSerializable(typeof(PersonStruct?))] |
| 53 | +// [JsonSerializable(typeof(TypeWithValidationAttributes))] |
| 54 | +// [JsonSerializable(typeof(TypeWithDerivedAttribute))] |
| 55 | +// [JsonSerializable(typeof(PolymorphicClass))] |
| 56 | +// [JsonSerializable(typeof(PocoWithNumberHandlingAttr))] |
| 57 | +// [JsonSerializable(typeof(PocoWithMixedVisibilityMembers))] |
58 | 58 | internal partial class MetadataAndSerializationContext : JsonSerializerContext, ITestContext |
59 | 59 | { |
60 | 60 | public JsonSourceGenerationMode JsonSourceGenerationMode => JsonSourceGenerationMode.Default; |
|
0 commit comments