public XDocument GenerateResults()
 {
     var poi = new MockData().MakeTestPoi();
     var serializer = new Serializer();
     serializer.Serialize(new Results(new List<Poi> {poi}));
     return serializer.Serialize(new Results(new List<Poi> { poi })); 
 }
 public void Serialize_OneLoadedPois_ReturnsXDocumentWithLoadedPoiNode()
 {
     var serializer = new Serializer();
     var mock = new MockData();
     var doc = serializer.Serialize(mock.MakeResult(mock.MakeTestPoi()));
     doc.Root.Descendants().Where(n => n.Name.LocalName == "poi").Should().HaveCount(1);
 }
Ejemplo n.º 3
0
 public void NewResult_WithTwoPoiInList_ContainsTwoPoiInResult()
 {
     var result = new MockData().MakeResultWithTwoEmptyPois();
     result.Value.Should().HaveCount(2);
 }
Ejemplo n.º 4
0
 public void NewResult_WithOnePoiInList_ContainsOnePoiInResult()
 {
     var result = new MockData().MakeResultWithOneEmptyPoi();
     result.Value.Should().HaveCount(1);
 }