public void WrongInputPostField() { var serializer = new PostFieldSerializer(); Assert.Throws <ArgumentException>(() => serializer.Serialize(new DateField { Value = DateTime.Now })); }
public void SerializePostField() { var serializer = new PostFieldSerializer(); var postId = Guid.NewGuid(); var str = serializer.Serialize(new PostField { Id = postId }); Assert.Equal(postId.ToString(), str); }