Skip to content

Commit 642fefc

Browse files
author
zhengsl
committed
新增1d解码编码单元测试
1 parent 789c10f commit 642fefc

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

GeoSOT.xUnitTests/TileTest.cs

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public void TileBboxLevel15(string input, string expected)
3737

3838
[Theory]
3939
[InlineData("G001110221-021123", "15 7245 403")]
40-
public void TileDecode1DString(string input, string expected)
40+
public void TileDecode1DStringToLXY(string input, string expected)
4141
{
4242
//Arrange
4343
var _tile = new Tile(input);
@@ -49,5 +49,20 @@ public void TileDecode1DString(string input, string expected)
4949
Assert.Equal(expected, actual);
5050
}
5151

52+
53+
[Theory]
54+
[InlineData("G001110221-021123-021123.02203010012", "G001110221-021123-021123.02203010012")]
55+
public void Tile1DStringDecodeAndEncode(string input, string expected)
56+
{
57+
//Arrange
58+
var _tile = new Tile(input);
59+
60+
//Act
61+
var actual = _tile.ToString();
62+
63+
//Assert
64+
Assert.Equal(expected, actual);
65+
}
66+
5267
}
5368
}

0 commit comments

Comments
 (0)