31 references to GetSerializer
System.Windows.Forms.Design (1)
System\ComponentModel\Design\Serialization\DesignerSerializationManager.cs (1)
848
return
GetSerializer
(objectType, serializerType);
System.Windows.Forms.Design.Tests (30)
System\ComponentModel\Design\Serialization\DesignerSerializationManagerTests.cs (30)
581
object serializer1 = manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass));
583
Assert.Same(serializer1, manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(PublicDesignerSerializationProvider)));
587
object serializer2 = manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass));
590
Assert.NotSame(serializer2, manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass)));
1183
Assert.Same(expected, manager.
GetSerializer
(objectType, serializerType));
1186
Assert.Same(expected, manager.
GetSerializer
(objectType, serializerType));
1196
Assert.Same(expected, manager.
GetSerializer
(objectType, serializerType));
1199
Assert.Same(expected, manager.
GetSerializer
(objectType, serializerType));
1213
object serializer1 = manager.
GetSerializer
(objectType, typeof(BaseClass));
1217
object serializer2 = manager.
GetSerializer
(objectType, typeof(BaseClass));
1222
Assert.Null(manager.
GetSerializer
(objectType, expectedSerializerType));
1225
Assert.Null(manager.
GetSerializer
(objectType, expectedSerializerType));
1228
Assert.Null(manager.
GetSerializer
(objectType, typeof(object)));
1231
Assert.Null(manager.
GetSerializer
(objectType, typeof(object)));
1234
Assert.Null(manager.
GetSerializer
(objectType, typeof(int)));
1237
Assert.Null(manager.
GetSerializer
(objectType, typeof(int)));
1246
object serializer1 = manager.
GetSerializer
(objectType, typeof(BaseClass));
1250
object serializer2 = manager.
GetSerializer
(objectType, typeof(BaseClass));
1255
object serializer3 = manager.
GetSerializer
(objectType, expectedSerializerType);
1260
object serializer4 = manager.
GetSerializer
(objectType, expectedSerializerType);
1265
object serializer5 = manager.
GetSerializer
(objectType, typeof(object));
1270
object serializer6 = manager.
GetSerializer
(objectType, typeof(object));
1275
Assert.Null(manager.
GetSerializer
(objectType, typeof(int)));
1278
Assert.Null(manager.
GetSerializer
(objectType, typeof(int)));
1285
Assert.Throws<MissingMethodException>(() => manager.
GetSerializer
(null, typeof(ClassWithInterfaceDefaultSerializationProvider)));
1293
Assert.Throws<ArgumentNullException>("serializerType", () => manager.
GetSerializer
(objectType, null));
1762
object serializer1 = manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass));
1764
Assert.Same(serializer1, manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(PublicDesignerSerializationProvider)));
1768
object serializer2 = manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass));
1771
Assert.NotSame(serializer2, manager.
GetSerializer
(typeof(ClassWithPublicDesignerSerializer), typeof(BaseClass)));