public void TestCompareWithAnonymousMethod3()
        {
            var d = new MonthlyAccountingBasedSummary
            {
                ClientId       = "TestClient",
                FundingExpense = 100
            };

            var d2 = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient2"
            };

            var failResults = d.Compare(d2,
                                        new[]
            {
                nameof(MonthlyAccountingBasedSummary.ClientId),
                nameof(MonthlyAccountingBasedSummary.TotalRealizedIncomeBasis)
            })
                              .Where(r => r.IsMatch == false).ToArray();

            Assert.AreEqual(failResults.Length, 1);
            Assert.AreEqual(failResults[0].FieldName, "ClientId");
            Assert.AreEqual(failResults[0].ToValue, "TestClient2");
        }
        public void TestCompareToWithAnonymousMethod3()
        {
            var d = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient"
            };

            var d2 = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient"
            };

            Assert.AreEqual(d.CompareTo(d2), true);
        }
        public void TestCompareWithAnonymousMethod()
        {
            var d = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient"
            };

            var d2 = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient2"
            };

            var failResults = d.Compare(d2).Where(r => r.IsMatch == false).ToArray();

            Assert.AreEqual(failResults.Length, 1);
            Assert.AreEqual(failResults[0].FieldName, "ClientId");
            Assert.AreEqual(failResults[0].ToValue, "TestClient2");
        }
        public void TestCompareToWithAnonymousMethod5()
        {
            var d = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient"
            };

            var d2 = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient2"
            };

            var compareSucceeded = d.CompareTo(d2,
                                               new[]
            {
                nameof(MonthlyAccountingBasedSummary.HedgeInstrumentGainLoss),
                nameof(MonthlyAccountingBasedSummary.TotalIncome)
            });

            Assert.AreEqual(compareSucceeded, true);
        }
        public void TestCompareWithAnonymousMethod2()
        {
            var d = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient"
            };

            var d2 = new MonthlyAccountingBasedSummary
            {
                ClientId = "TestClient2"
            };

            var failResults = d.Compare(d2,
                                        new[]
            {
                nameof(MonthlyAccountingBasedSummary.InterestIncome),
                nameof(MonthlyAccountingBasedSummary.TotalRealizedIncomeBasis)
            })
                              .Where(r => r.IsMatch == false).ToArray();

            Assert.AreEqual(failResults.Length, 0);
        }