public void CheckNullsAreTreatedAsZeros_Equality(IObjectComparerPlugin plugin, object value)
        {
            {
                var output = plugin.TryCompare("key", value, null);

                Assert.Equal(ComparisonResultType.Equal, output.ComparisonResultType);
            }

            {
                var output = plugin.TryCompare("key", null, value);

                Assert.Equal(ComparisonResultType.Equal, output.ComparisonResultType);
            }
        }
        public void StandardBehaviour(IObjectComparerPlugin plugin, object expected, object actual, object expectedDifference)
        {
            var result = plugin.TryCompare("value", expected, actual);

            Assert.Equal(ComparisonResultType.Different, result.ComparisonResultType);
            Assert.Equal(result.Payload, expectedDifference);
        }
        public void CheckNumericOverflowBehaviour(IObjectComparerPlugin plugin, object expected, object actual, object expectedDifference)
        {
            var output = plugin.TryCompare("key", expected, actual);

            Assert.Equal(ComparisonResultType.Different, output.ComparisonResultType);
            Assert.Equal(expectedDifference, output.Payload);
        }
        public void CheckNullsAreTreatedAsZeros_Differences(IObjectComparerPlugin plugin, object value, object expectedDifferenceWhenExpectedIsNull, object expectedDifferenceWhenActualIsNull)
        {
            {
                var output = plugin.TryCompare("key", value, null);

                Assert.Equal(ComparisonResultType.Different, output.ComparisonResultType);
                Assert.NotNull(output.Payload);
                Assert.Equal(expectedDifferenceWhenActualIsNull, output.Payload);
            }

            {
                var output = plugin.TryCompare("key", null, value);

                Assert.Equal(ComparisonResultType.Different, output.ComparisonResultType);
                Assert.NotNull(output.Payload);
                Assert.Equal(expectedDifferenceWhenExpectedIsNull, output.Payload);
            }
        }