Skip to content

Commit f6d63d9

Browse files
committed
Add a test
1 parent 795b51b commit f6d63d9

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/FirebirdSql.Data.FirebirdClient.Tests/FbZonedDateTimeTypeTests.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,14 @@ public void EqualityFalse(FbZonedDateTime expected, FbZonedDateTime actual)
4747
Assert.AreNotEqual(expected, actual);
4848
}
4949

50+
[Test]
51+
public void ConvertToDateTimeShouldNotThrow()
52+
{
53+
FbZonedDateTime fbZonedDateTime = new(new DateTime(2020, 12, 4, 10, 38, 0, DateTimeKind.Utc), "UTC");
54+
55+
Assert.DoesNotThrow(() => Convert.ChangeType(fbZonedDateTime, typeof(DateTime)));
56+
}
57+
5058
public void DateTimeShouldBeUtc()
5159
{
5260
Assert.Throws<ArgumentException>(() =>

0 commit comments

Comments
 (0)