1
0
mirror of https://github.com/oliverbooth/X10D synced 2024-11-22 07:58:49 +00:00

fix(tests): add test to fix coverage on DateOnly.Deconstruct

This commit is contained in:
Oliver Booth 2024-02-12 02:35:17 +00:00
parent 6750f0e3db
commit f679ec294e
Signed by: oliverbooth
GPG Key ID: E60B570D1B7557B5

View File

@ -39,6 +39,18 @@ internal class DateOnlyTests
Assert.That(age, Is.EqualTo(18));
}
[Test]
public void Deconstruct_ShouldDeconstruct_GivenDateOnly()
{
var date = new DateOnly(2017, 12, 31);
date.Deconstruct(out int year, out int month, out int day);
Assert.That(year, Is.EqualTo(2017));
Assert.That(month, Is.EqualTo(12));
Assert.That(day, Is.EqualTo(31));
}
[Test]
public void Deconstruct_ShouldDeconstructToTuple_GivenDateOnly()
{