R
RRB
Hi,
I have a class library in which I have classes which implement
ISerializable. They all have GetObjectData implementations and
constructors to support deserialization.
In unit testing this library, I discovered that my classes were being
serialized by XmlSerializer using the default behavior of traversing the
public g/s properties.
My unit test app is a console program and nothing is being downloaded.
At first I set breakpoints to trap the process, but when that failed, I
altered the GetObjectData() method in one class to cause the generation
recognizably-inaccurate but still-legal xml data by omitting calling
AddValue for a couple properties.
Sure enough, XmlSerializer blithely generated Xml that had the omitted
properties proving my GetObjectData method was not being called. The
class I isolated on to test this is a public base class.
Anyone know what the problem could be? I can attach the code but
really, it's no different than the thousand basic examples out there for
implementing ISerializable.
Any help would be dearly appreciated!
======================
blackbox testing prerequisites:
1 white box
1 black marker
I have a class library in which I have classes which implement
ISerializable. They all have GetObjectData implementations and
constructors to support deserialization.
In unit testing this library, I discovered that my classes were being
serialized by XmlSerializer using the default behavior of traversing the
public g/s properties.
My unit test app is a console program and nothing is being downloaded.
At first I set breakpoints to trap the process, but when that failed, I
altered the GetObjectData() method in one class to cause the generation
recognizably-inaccurate but still-legal xml data by omitting calling
AddValue for a couple properties.
Sure enough, XmlSerializer blithely generated Xml that had the omitted
properties proving my GetObjectData method was not being called. The
class I isolated on to test this is a public base class.
Anyone know what the problem could be? I can attach the code but
really, it's no different than the thousand basic examples out there for
implementing ISerializable.
Any help would be dearly appreciated!
======================
blackbox testing prerequisites:
1 white box
1 black marker