-
Notifications
You must be signed in to change notification settings - Fork 21
Description
Hi
i try to get the model under test for testing the serialization. So I use the Set - Methods like "SetAccount" and I use the Properties directly. It will caused an Exception.
var agent = new Agent();
agent.Accounts.Add(CreateOnlineAccount());
agent.Addresses.Add(CreateAddress());
agent.Emails.Add(CreateRessource());
agent.Homepage = CreateRessource();
agent.Identifiers.Add(CreateIdentifier());
agent.Names.Add(CreateTextValue());
agent.Openid = CreateRessource();
agent.Phones.Add(CreateRessource());
agent.Id = "id";
agent.Links.Add(CreateLink());
Why the error happened is clear to me, but why was it realized so? Can not you simply initialize the properties and remove the methods?
I have fixed the issue in #43 but if this have a deeper meaning I would be glad to learn it