Kyoo/Kyoo.Tests/KAssert.cs
2021-05-29 18:28:38 +02:00

14 lines
298 B
C#

using System.Reflection;
using Xunit;
namespace Kyoo.Tests
{
public static class KAssert
{
public static void DeepEqual<T>(T expected, T value)
{
foreach (PropertyInfo property in typeof(T).GetProperties())
Assert.Equal(property.GetValue(expected), property.GetValue(value));
}
}
}