Skip to content

Commit ccd086a

Browse files
DOC-2525 another attempt to fix test string formatting
1 parent b83b108 commit ccd086a

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

tests/Doc/Geo_tutorial.cs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,16 @@ public void run()
6767
Assert.Equal(3, res4.Length);
6868

6969
Assert.Equal("station:1", res4[0].Member);
70-
Assert.Equal(new GeoPosition(-122.27652, 37.805186), res4[0].Position);
70+
GeoPosition pos1 = res4[0].Position ?? new GeoPosition();
71+
Assert.Equal("-122.27652, 37.80518", $"{pos1.Longitude:F5}, {pos1.Latitude:F5}");
7172

7273
Assert.Equal("station:2", res4[1].Member);
73-
Assert.Equal(new GeoPosition(-122.2674626, 37.8062344), res4[1].Position);
74+
GeoPosition pos2 = res4[1].Position ?? new GeoPosition();
75+
Assert.Equal("-122.26746, 37.80623", $"{pos2.Longitude:F5}, {pos2.Latitude:F5}");
7476

7577
Assert.Equal("station:3", res4[2].Member);
76-
Assert.Equal(new GeoPosition(-122.2469854, 37.8104049), res4[2].Position);
78+
GeoPosition pos3 = res4[2].Position ?? new GeoPosition();
79+
Assert.Equal("-122.24699, 37.81040", $"{pos3.Longitude:F5}, {pos3.Latitude:F5}");
7780
// REMOVE_END
7881

7982

0 commit comments

Comments
 (0)