public void SetUp() { this.typeMapper = new Config().CreateSessionFactory().TypeMapper; this.deserializer = new PomonaJsonDeserializer(new ServerSerializationContextProvider(this.typeMapper, Substitute.For <IUriResolver>(), Substitute.For <IResourceResolver>(), new NoContainer())); }
public void SetUp() { var factory = new PomonaJsonSerializerFactory(new ClientSerializationContextProvider(this.clientTypeMapper, Substitute.For<IPomonaClient>())); this.deserializer = factory.GetDeserializer(); }
public void SetUp() { var factory = new PomonaJsonSerializerFactory(); var pomonaClient = Substitute.For <IPomonaClient>(); this.deserializer = factory.GetDeserializer(new ClientSerializationContextProvider(this.clientTypeMapper, pomonaClient, pomonaClient)); }
private T Deserialize <T>(string jsonString) { var pomonaClient = Substitute.For <IPomonaClient>(); var jsonDeserializer = new PomonaJsonDeserializer( new ClientSerializationContextProvider(this.typeMapper, pomonaClient, pomonaClient)); return(jsonDeserializer.DeserializeString <T>(jsonString)); }