fixed minor bug in the test value ranomizer

This commit is contained in:
David Sparer
2019-04-01 13:18:38 -05:00
parent 0359e75de7
commit ccfac74cc3

View File

@@ -6,7 +6,7 @@ using Enum = System.Enum;
namespace mRemoteNGTests.TestHelpers
{
internal static class Randomizer
internal static class Randomizer
{
private static readonly Random Random = new Random();
@@ -98,7 +98,8 @@ namespace mRemoteNGTests.TestHelpers
if (opByType.TryGetValue(property.PropertyType, out var mutator))
mutator(property, con);
else if (opByType.TryGetValue(property.PropertyType.BaseType, out var mutator2))
else if (property.PropertyType.BaseType != null &&
opByType.TryGetValue(property.PropertyType.BaseType, out var mutator2))
mutator2(property, con);
}